Oh, _that's_ why that `if' had the sense it did. Good grief.
authorsimon <simon@cda61777-01e9-0310-a592-d414129be87e>
Tue, 28 Jan 2003 09:26:32 +0000 (09:26 +0000)
committersimon <simon@cda61777-01e9-0310-a592-d414129be87e>
Tue, 28 Jan 2003 09:26:32 +0000 (09:26 +0000)
Apparently I used to rely on the fact that the same `erase_char'
used to wipe parts of the screen was also a good value to use for
resetting line attributes. Should now be more robust against future
reorganisations of the ATTR_* bit fields.

git-svn-id: svn://svn.tartarus.org/sgt/putty@2740 cda61777-01e9-0310-a592-d414129be87e

terminal.c

index e3e8cc0..6e05646 100644 (file)
@@ -975,8 +975,10 @@ static void erase_lots(Terminal *term,
     ldata = lineptr(start.y);
     while (poslt(start, end)) {
        if (start.x == term->cols) {
-            if (erase_lattr)
-                ldata[start.x] &= ~(LATTR_WRAPPED | LATTR_WRAPPED2);
+            if (!erase_lattr)
+                ldata[start.x] = ~(LATTR_WRAPPED | LATTR_WRAPPED2);
+            else
+                ldata[start.x] = LATTR_NORM;
         } else {
            ldata[start.x] = term->erase_char;
         }