diff options
author | Caolán McNamara <caolanm@redhat.com> | 2020-04-16 20:38:12 +0100 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2020-04-16 22:24:48 +0200 |
commit | a435887eaf747d9b17b3620884ac2ec06d63ac00 (patch) | |
tree | b3c87f1a46be2d3d9b79eb6f5ccd7c2729c31756 /soltools | |
parent | 4830592b780833cf5eee2aef30bc9c5d444dfb24 (diff) |
cid#1462267 Infinite loop
since...
commit a2362e0ff5a7cec16e888502a3c16fe2fa7ba0fe
Date: Wed Apr 15 19:32:09 2020 +0200
loplugin:buriedassign in sfx2..sot
Change-Id: Iabbef1b027cb6bd77b387142df926c5b37858517
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/92392
Tested-by: Jenkins
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
Diffstat (limited to 'soltools')
-rw-r--r-- | soltools/cpp/_eval.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/soltools/cpp/_eval.c b/soltools/cpp/_eval.c index e8b679ea93e1..dba04abf4649 100644 --- a/soltools/cpp/_eval.c +++ b/soltools/cpp/_eval.c @@ -726,9 +726,11 @@ struct value if (*p == 'x') { p += 1; - i = digit(*p); - while (i >= 0 && i <= 15) + while (1) { + i = digit(*p); + if (i < 0 || i > 16) + break; p += 1; n <<= 4; n += i; |