Module Name:    src
Committed By:   jdc
Date:           Thu Jun 16 22:45:46 UTC 2011

Modified Files:
        src/lib/libcurses: refresh.c

Log Message:
Correctly test for __ISDIRTY.
Problem noticed by (and test case provided by) blymn@.


To generate a diff of this commit:
cvs rdiff -u -r1.73 -r1.74 src/lib/libcurses/refresh.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/lib/libcurses/refresh.c
diff -u src/lib/libcurses/refresh.c:1.73 src/lib/libcurses/refresh.c:1.74
--- src/lib/libcurses/refresh.c:1.73	Mon Feb  8 20:45:22 2010
+++ src/lib/libcurses/refresh.c	Thu Jun 16 22:45:46 2011
@@ -1,4 +1,4 @@
-/*	$NetBSD: refresh.c,v 1.73 2010/02/08 20:45:22 roy Exp $	*/
+/*	$NetBSD: refresh.c,v 1.74 2011/06/16 22:45:46 jdc Exp $	*/
 
 /*
  * Copyright (c) 1981, 1993, 1994
@@ -34,7 +34,7 @@
 #if 0
 static char sccsid[] = "@(#)refresh.c	8.7 (Berkeley) 8/13/94";
 #else
-__RCSID("$NetBSD: refresh.c,v 1.73 2010/02/08 20:45:22 roy Exp $");
+__RCSID("$NetBSD: refresh.c,v 1.74 2011/06/16 22:45:46 jdc Exp $");
 #endif
 #endif				/* not lint */
 
@@ -174,7 +174,7 @@
 			    orig, sub_win);
 #endif
 			for (sy = 0; sy < sub_win->maxy; sy++) {
-				if (sub_win->alines[sy]->flags == __ISDIRTY) {
+				if (sub_win->alines[sy]->flags & __ISDIRTY) {
 					orig->alines[sy + sub_win->begy - orig->begy]->flags
 					    |= __ISDIRTY;
 					sub_win->alines[sy]->flags

Reply via email to