Thread: pgsql: Protect against hypothetical memory leaks inRelationGetPartitio

pgsql: Protect against hypothetical memory leaks inRelationGetPartitio

From
Alvaro Herrera
Date:
Protect against hypothetical memory leaks in RelationGetPartitionKey

Also, fix a comment that commit 8a0596cb656e made obsolete.

Reported-by: Robert Haas
Discussion: http://postgr.es/m/CA+TgmoYbpuUUUp2GhYNwWm0qkah39spiU7uOiNXLz20ASfKYoA@mail.gmail.com

Branch
------
master

Details
-------
https://git.postgresql.org/pg/commitdiff/be2343221fb74bde6b7445feeef32f7ea5cf2618

Modified Files
--------------
src/backend/utils/cache/relcache.c | 53 +++++++++++++++++++++-----------------
src/include/access/hash.h          |  2 +-
2 files changed, 30 insertions(+), 25 deletions(-)