mirror of
https://github.com/postgres/postgres.git
synced 2026-05-17 20:09:41 -04:00
The function looped over ii_NumIndexKeyAttrs elements of the skeys array, but one caller (ri_FastPathFlushArray) passes a one-element array since it only handles single-column FKs. The function signature did not communicate this constraint, which static analysis flags as a potential out-of-bounds read. Add an nkeys parameter and assert that it matches ii_NumIndexKeyAttrs, then use it in the loop. The call sites already know the key count. Reported-by: Evan Montgomery-Recht <montge@mianetworks.net> Discussion: https://postgr.es/m/CAEg7pwcKf01FmDqFAf-Hzu_pYnMYScY_Otid-pe9uw3BJ6gq9g@mail.gmail.com |
||
|---|---|---|
| .. | ||
| backend | ||
| bin | ||
| common | ||
| fe_utils | ||
| include | ||
| interfaces | ||
| makefiles | ||
| pl | ||
| port | ||
| template | ||
| test | ||
| timezone | ||
| tools | ||
| tutorial | ||
| .gitignore | ||
| DEVELOPERS | ||
| Makefile | ||
| Makefile.global.in | ||
| Makefile.shlib | ||
| meson.build | ||
| nls-global.mk | ||