summaryrefslogtreecommitdiff
path: root/src/charset.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/charset.c')
-rw-r--r--src/charset.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/charset.c b/src/charset.c
index 0535d4cfc..cc02563b2 100644
--- a/src/charset.c
+++ b/src/charset.c
@@ -1218,6 +1218,8 @@ in_win_border(wp, vcol)
if ((int)vcol == width1 - 1)
return TRUE;
width2 = width1 + win_col_off2(wp);
+ if (width2 <= 0)
+ return FALSE;
return ((vcol - width1) % width2 == width2 - 1);
}
#endif /* FEAT_MBYTE */