]> git.ipfire.org Git - thirdparty/haproxy.git/commit
BUG/MINOR: ist: only store NUL byte on succeeded alloc
authorWilly Tarreau <w@1wt.eu>
Fri, 23 Feb 2024 18:51:54 +0000 (19:51 +0100)
committerWilly Tarreau <w@1wt.eu>
Fri, 23 Feb 2024 18:51:54 +0000 (19:51 +0100)
commita4d44250ebda83aac986d94e49004c470a19681e
treea577f8c6ca4d04467a23c763ec67e76235eb55dc
parent3f771f5118fb028489603d72e1dc9486fcc61a52
BUG/MINOR: ist: only store NUL byte on succeeded alloc

The trailing NUL added at the end of istdup() by recent commit de0216758
("BUG/MINOR: ist: allocate nul byte on istdup") was placed outside of
the pointer validity test, rightfully showing null deref warnings. This
fix should be backported along with the fix above, to the same versions.
include/import/ist.h