]> git.ipfire.org Git - thirdparty/haproxy.git/commit
CLEANUP: ncbmbuf: improve handling of memory allocation errors in unit tests
authorIlia Shipitsin <chipitsine@gmail.com>
Sun, 31 May 2026 07:14:39 +0000 (09:14 +0200)
committerWilly Tarreau <w@1wt.eu>
Sun, 31 May 2026 08:29:49 +0000 (10:29 +0200)
commitc1d6973571a4c6798f746c6a64e9d71b46ab49e5
treeea0ae813bb3f3f83a673ad45b876f2c9f035f1dc
parenta93b407811f348e7d5f0c631c6277f8814f050c4
CLEANUP: ncbmbuf: improve handling of memory allocation errors in unit tests

Found via cppcheck  --force --enable=all --output-file=haproxy.log :

src/ncbmbuf.c:192:9: warning: If memory allocation fails, then there is a possible null pointer dereference: area [nullPointerOutOfMemory]
src/ncbmbuf.c:373:9: warning: If memory allocation fails, then there is a possible null pointer dereference: data [nullPointerOutOfMemory]
src/ncbmbuf.c:546:9: warning: If memory allocation fails, then there is a possible null pointer dereference: data [nullPointerOutOfMemory]
src/ncbmbuf.c