Fix UTF-8 handling when running the game, env-vars, and setting the project path (#1632)

* fix utf-8 handling around env-vars

* fix file opening errors related to unicode

* add uncaught exception handler in `gk` to ensure something is logged

* gracefully fail if window icon cant be loaded and work with unicode

* linux fix and add changes to vendor file
This commit is contained in:
Tyler Wilding
2022-07-10 19:03:24 -04:00
committed by GitHub
parent 63ac19440c
commit 1b67d1dc77
21 changed files with 198 additions and 168 deletions
+3 -7
View File
@@ -18,14 +18,10 @@
#include "decompiler/level_extractor/extract_level.h"
int main(int argc, char** argv) {
#ifdef _WIN32
auto args = get_widechar_cli_args();
std::vector<char*> string_ptrs;
for (auto& str : args) {
string_ptrs.push_back(str.data());
fs::u8arguments u8guard(argc, argv);
if (!u8guard.valid()) {
exit(EXIT_FAILURE);
}
argv = string_ptrs.data();
#endif
Timer decomp_timer;