]> granicus.if.org Git - nethack/commitdiff
reports on windows of partial status lines after level change
authornhmall <nhmall@nethack.org>
Sat, 1 Sep 2018 18:52:47 +0000 (14:52 -0400)
committernhmall <nhmall@nethack.org>
Sat, 1 Sep 2018 18:52:47 +0000 (14:52 -0400)
tty: turn off an optimization that is the suspected cause of Windows reported
partial status lines following level changes. It was turned on for
        non-unix platforms only

doc/fixes36.2
win/tty/wintty.c

index 803c0abd9ecc45ee82498626493fd8a0fe7ccc9c..fbf1544bae8220dca75368627c56a6cf56db8662 100644 (file)
@@ -112,6 +112,8 @@ fix access violation when --debug:xxxx has no other args after it
 setting the inverse attribute for gold had the space before "$:"
        getting highlighted along with the gold field
 sortloot segfaulted when filtering a subset of items (seen with 'A' command)
+tty: turn off an optimization that is the suspected cause of Windows reported 
+       partial status lines following level changes
 
 
 Platform- and/or Interface-Specific Fixes
index 42dad00c2996b28be9c890ff330b552bdfd46721..a0e2f66ed7d797a105ec2c08ebcbe22a013a5711 100644 (file)
@@ -3552,11 +3552,13 @@ static boolean truncation_expected = FALSE;
  * for all platforms eventually and the conditional
  * setting below can be removed.
  */
-#if defined(UNIX)
-static int do_field_opt = 0;
+static int do_field_opt = 
+#if defined(ENABLE_TTY_FIELD_OPT)
+    1;
 #else
-static int do_field_opt = 1;
+    0;
 #endif
+
 #endif  /* STATUS_HILITES */
 
 /*
@@ -3691,7 +3693,8 @@ unsigned long *colormasks;
 
     /* The core botl engine sends a single blank to the window port
        for carrying-capacity when its unused. Let's suppress that */
-    if (tty_status[NOW][fldidx].lth == 1 && status_vals[fldidx][0] == ' ') {
+    if (fldidx != BL_FLUSH &&
+            tty_status[NOW][fldidx].lth == 1 && status_vals[fldidx][0] == ' ') {
         status_vals[fldidx][0] = '\0';
         tty_status[NOW][fldidx].lth = 0;
     }