summaryrefslogtreecommitdiff
path: root/src/textprop.c
diff options
context:
space:
mode:
authorBram Moolenaar <Bram@vim.org>2022-09-14 12:06:53 +0100
committerBram Moolenaar <Bram@vim.org>2022-09-14 12:06:53 +0100
commit98b373075e9a2ed642bc89f4f543e31d1428466f (patch)
treecbcfe1e273af6bccb52c3cf9f29535bcf28d5ece /src/textprop.c
parent470a14140bc06f1653edf26ab0b3c9b801080353 (diff)
downloadvim-git-98b373075e9a2ed642bc89f4f543e31d1428466f.tar.gz
patch 9.0.0462: ASAN warning for integer overflowv9.0.0462
Problem: ASAN warning for integer overflow. Solution: Check for tp_col to be MAXCOL.
Diffstat (limited to 'src/textprop.c')
-rw-r--r--src/textprop.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/textprop.c b/src/textprop.c
index d2536ce77..ba21e751b 100644
--- a/src/textprop.c
+++ b/src/textprop.c
@@ -2289,7 +2289,7 @@ adjust_props_for_split(
*p = prop;
++prevprop.ga_len;
- if (p->tp_col + p->tp_len >= kept)
+ if (p->tp_col != MAXCOL && p->tp_col + p->tp_len >= kept)
p->tp_len = kept - p->tp_col;
if (cont_next)
p->tp_flags |= TP_FLAG_CONT_NEXT;