summaryrefslogtreecommitdiff
path: root/pico/display.c
diff options
context:
space:
mode:
Diffstat (limited to 'pico/display.c')
-rw-r--r--pico/display.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/pico/display.c b/pico/display.c
index e0cf4c5a..468de2ce 100644
--- a/pico/display.c
+++ b/pico/display.c
@@ -1065,7 +1065,7 @@ updatelinecolor (int row, CELL vline[], CELL pline[], short *flags, int len)
* are spaces or not.
*/
cp3 = &vline[0];
- for(w = 0; w < term.t_ncol; cp3++){
+ for(w = 0; w < term.t_ncol && cp3 < &vline[term.t_ncol]; cp3++){
int ww;
ww = wcellwidth((UCS) cp3->c);