git.postgresql.org Git - postgresql.git/commit

git projects / postgresql.git / commit
? search:
summary | shortlog | log | commit | commitdiff | tree
(parent: a7e5237) | patch
jsonapi: fix memory leakage during OOM error recovery.
2024年9月23日 16:30:51 +0000 (12:30 -0400)
2024年9月23日 16:30:51 +0000 (12:30 -0400)
commit 75240f65e700d7d157be27653c70fe75108f25c1
jsonapi: fix memory leakage during OOM error recovery.

Coverity pointed out that inc_lex_level() would leak memory
(not to mention corrupt the pstack data structure) if some
but not all of its three REALLOC's failed. To fix, store
successfully-updated pointers back into the pstack struct
immediately.

Oversight in 0785d1b8b, so no need for back-patch.
src/common/jsonapi.c diff | blob | blame | history
This is the main PostgreSQL git repository.
RSS Atom

AltStyle によって変換されたページ (->オリジナル) /