mirror of
https://github.com/kanjitalk755/macemu.git
synced 2025-01-05 14:32:15 +00:00
bug-fix: OS X app would not launch, when run from the Finder
This commit is contained in:
parent
a1a85a9315
commit
3d0ea018ed
@ -427,11 +427,18 @@ int main(int argc, char **argv)
|
||||
} else if (strcmp(argv[i], "--rominfo") == 0) {
|
||||
argv[i] = NULL;
|
||||
PrintROMInfo = true;
|
||||
} else if (strcmp(argv[i], "-NSDocumentRevisionsDebugMode") == 0) {
|
||||
// HACK: prevent Basilisk from exiting, when run via Xcode 8, which
|
||||
// passes in a '-NSDocumentRevisionsDebugMode' option.
|
||||
}
|
||||
|
||||
#if defined(__APPLE__) && defined(__MACH__)
|
||||
// Mac OS X likes to pass in various options of its own, when launching an app.
|
||||
// Attempt to ignore these.
|
||||
const char * mac_psn_prefix = "-psn_";
|
||||
if (strcmp(argv[i], "-NSDocumentRevisionsDebugMode") == 0) {
|
||||
argv[i] = NULL;
|
||||
} else if (strncmp(mac_psn_prefix, argv[i], strlen(mac_psn_prefix)) == 0) {
|
||||
argv[i] = NULL;
|
||||
}
|
||||
#endif
|
||||
}
|
||||
|
||||
// Remove processed arguments
|
||||
|
Loading…
Reference in New Issue
Block a user