Fix allocation formula in llvmjit_expr.c REL_17_STABLE github/REL_17_STABLE
authorMichael Paquier <[email protected]>
Thu, 11 Dec 2025 01:25:46 +0000 (10:25 +0900)
committerMichael Paquier <[email protected]>
Thu, 11 Dec 2025 01:25:46 +0000 (10:25 +0900)
commit0bab0c3b74af29d05bdd401c8ebe658389a64507
tree2c27177733dde5ade022cf699af34a97647137f6
parent807b2f261d643944120d29bfab70937ebbd4aad6
Fix allocation formula in llvmjit_expr.c

An array of LLVMBasicBlockRef is allocated with the size used for an
element being "LLVMBasicBlockRef *" rather than "LLVMBasicBlockRef".
LLVMBasicBlockRef is a type that refers to a pointer, so this did not
directly cause a problem because both should have the same size, still
it is incorrect.

This issue has been spotted while reviewing a different patch, and
exists since 2a0faed9d702, so backpatch all the way down.

Discussion: https://postgr.es/m/CA+hUKGLngd9cKHtTUuUdEo2eWEgUcZ_EQRbP55MigV2t_zTReg@mail.gmail.com
Backpatch-through: 14
src/backend/jit/llvm/llvmjit_expr.c