Main: force UTF-8 locale.
This commit is contained in:
parent
a33cbdfad6
commit
714d8cc6bb
1 changed files with 7 additions and 0 deletions
|
@ -25,6 +25,13 @@
|
||||||
#include "SaveTool/SaveTool.h"
|
#include "SaveTool/SaveTool.h"
|
||||||
|
|
||||||
int main(int argc, char** argv) {
|
int main(int argc, char** argv) {
|
||||||
|
auto str = std::setlocale(LC_ALL, ".utf-8");
|
||||||
|
if(str && !Containers::StringView{str}.hasSuffix(".utf8")) {
|
||||||
|
SDL_ShowSimpleMessageBox(SDL_MESSAGEBOX_ERROR, "Error",
|
||||||
|
"Your system doesn't support UTF-8.", nullptr);
|
||||||
|
return EXIT_FAILURE;
|
||||||
|
}
|
||||||
|
|
||||||
#ifndef SAVETOOL_DEBUG_BUILD
|
#ifndef SAVETOOL_DEBUG_BUILD
|
||||||
std::ofstream output{"SaveToolLog.txt", std::ios::trunc|std::ios::out};
|
std::ofstream output{"SaveToolLog.txt", std::ios::trunc|std::ios::out};
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue