]> git.ipfire.org Git - thirdparty/glibc.git/commit
string: Fix UB on test-strrchr
authorAdhemerval Zanella <adhemerval.zanella@linaro.org>
Fri, 25 Apr 2025 16:04:33 +0000 (13:04 -0300)
committerAdhemerval Zanella <adhemerval.zanella@linaro.org>
Thu, 8 May 2025 12:25:49 +0000 (09:25 -0300)
commit9ae7611c80f43bfa515357e65c6818bb2e004088
tree44c9e6fb3efca314571d0dd9f679316d577bf5f2
parent180cbc0cc9cbc31f05ac2598cecf0ae498a76717
string: Fix UB on test-strrchr

UBSAN: Undefined behaviour in test-strrchr.c:100:35 unsigned integer overflow: 1804289383 * 846930886 cannot be represened in type 'long int'

Use int64_t operations instead.
string/test-strrchr.c