fix nethackw start without arguments

The Windows graphical version in NetHackW.exe is meant to lock
itself to its own windowtype and ignore the OPTIONS=windowtype
setting in the config file, but the code to perform the lock
only did so if (argc > 1).
This commit is contained in:
nhmall
2018-11-28 23:29:28 -05:00
parent c35c2df14d
commit 3634d16582

View File

@@ -1,4 +1,4 @@
/* NetHack 3.6 pcmain.c $NHDT-Date: 1524413707 2018/04/22 16:15:07 $ $NHDT-Branch: NetHack-3.6.0 $:$NHDT-Revision: 1.74 $ */
/* NetHack 3.6 pcmain.c $NHDT-Date: 1543465755 2018/11/29 04:29:15 $ $NHDT-Branch: NetHack-3.6.2-beta01 $:$NHDT-Revision: 1.101 $ */
/* Copyright (c) Stichting Mathematisch Centrum, Amsterdam, 1985. */
/*-Copyright (c) Derek S. Ray, 2015. */
/* NetHack may be freely redistributed. See license for details. */
@@ -177,7 +177,7 @@ _CrtSetReportFile(_CRT_ASSERT, _CRTDBG_FILE_STDERR);*/
choose_windows(DEFAULT_WINDOW_SYS);
#else
choose_windows(default_window_sys);
if (argc > 1
if (argc >= 1
&& !strcmpi(default_window_sys, "mswin")
&& strstri(argv[0], "nethackw.exe"))
iflags.windowtype_locked = TRUE;