]> git.kaiwu.me - njs.git/commit
CHB: avoid incompatible function pointer calls
authorDmitry Volyntsev <xeioex@nginx.com>
Sat, 12 Sep 2026 05:25:53 +0000 (22:25 -0700)
committerDmitry Volyntsev <xeioexception@gmail.com>
Mon, 14 Sep 2026 17:53:52 +0000 (10:53 -0700)
commit0c989ec195a1683c0557a4c43a2f51c4530db8b0
tree98bc262f43915ba50e49b1be12d8cbc50b6583c4
parent0851d594c64803446ad6284cceb9e0367db3f6a0
CHB: avoid incompatible function pointer calls

Use adapters for memory pool allocators instead of casting their function
pointers to the generic chain buffer callback types.

Casting does not make an indirect call through an incompatible function
pointer type valid.  UndefinedBehaviorSanitizer reports these calls.
src/njs_chb.c
src/njs_chb.h
src/qjs.c
src/qjs.h