Skip to content

Commit 5c45016

Browse files
committed
fix #2493
1 parent e6aa4bd commit 5c45016

1 file changed

Lines changed: 8 additions & 0 deletions

File tree

src/frontend/qt_sdl/main.cpp

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -288,6 +288,14 @@ int main(int argc, char** argv)
288288
if (argc != 0 && (!strcasecmp(argv[0], "derpDS") || !strcasecmp(argv[0], "./derpDS")))
289289
printf("did you just call me a derp???\n");
290290

291+
#ifdef _WIN32
292+
// argc and argv are passed as UTF8 by SDL's WinMain function
293+
// QT checks for the original value in local encoding though
294+
// to see whether it is unmodified to activate its hack that
295+
// retrieves the unicode value via CommandLineToArgvW.
296+
argc = __argc;
297+
argv = __argv;
298+
#endif
291299
MelonApplication melon(argc, argv);
292300
pathInit();
293301

0 commit comments

Comments
 (0)