summaryrefslogtreecommitdiff
path: root/src/include/access/heapam.h
diff options
context:
space:
mode:
authorDaniel Gustafsson2022-02-24 19:58:18 +0000
committerDaniel Gustafsson2022-02-24 19:58:18 +0000
commit31d8d4740ffb21c9898a21b5018c31e92af6935d (patch)
treebc662d7a0cd97701aa408ab1d83442d76586288d /src/include/access/heapam.h
parent6c46e8a5dfc9f49e673d76fc6ae097b81d7740ef (diff)
Guard against reallocation failure in pg_regress
realloc() will return NULL on a failed reallocation, so the destination pointer must be inspected to avoid null pointer dereference. Further, assigning the return value to the source pointer leak the allocation in the case of reallocation failure. Fix by using pg_realloc instead which has full error handling. Reviewed-by: Tom Lane <[email protected]> Discussion: https://postgr.es/m/[email protected]
Diffstat (limited to 'src/include/access/heapam.h')
0 files changed, 0 insertions, 0 deletions