1
0
Fork 0
mirror of https://git.rip/DMCA_FUCKER/re3.git synced 2024-10-31 23:05:55 +00:00

add -console cmdline arg instead of #if 0/1

This commit is contained in:
withmorten 2020-11-28 17:57:10 +01:00
parent ad48b9cde0
commit b1a431a740
2 changed files with 18 additions and 14 deletions

View file

@ -1453,12 +1453,14 @@ WinMain(HINSTANCE instance,
RwChar** argv;
SystemParametersInfo(SPI_SETFOREGROUNDLOCKTIMEOUT, 0, nil, SPIF_SENDCHANGE);
#if 0
// TODO: make this an option somewhere
#ifndef MASTER
if (strstr(cmdLine, "-console"))
{
AllocConsole();
freopen("CONIN$", "r", stdin);
freopen("CONOUT$", "w", stdout);
freopen("CONOUT$", "w", stderr);
}
#endif
#else

View file

@ -2011,16 +2011,18 @@ WinMain(HINSTANCE instance,
RwChar **argv;
SystemParametersInfo(SPI_SETFOREGROUNDLOCKTIMEOUT, 0, nil, SPIF_SENDCHANGE);
#ifdef USE_CUSTOM_ALLOCATOR
InitMemoryMgr();
#endif
#if 1
// TODO: make this an option somewhere
#ifndef MASTER
if (strstr(cmdLine, "-console"))
{
AllocConsole();
freopen("CONIN$", "r", stdin);
freopen("CONOUT$", "w", stdout);
freopen("CONOUT$", "w", stderr);
}
#endif
#ifdef USE_CUSTOM_ALLOCATOR
InitMemoryMgr();
#endif
/*