pgsql: Fix two small bugs in json's populate_record_worker

From: Andrew Dunstan <andrew(at)dunslane(dot)net>
To: pgsql-committers(at)postgresql(dot)org
Subject: pgsql: Fix two small bugs in json's populate_record_worker
Date: 2015-05-04 16:43:59
Message-ID: E1YpJTL-0005qf-JP@gemulon.postgresql.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-committers

Fix two small bugs in json's populate_record_worker

The first bug is not releasing a tupdesc when doing an early return out
of the function. The second bug is a logic error in choosing when to do
an early return if given an empty jsonb object.

Bug reports from Pavel Stehule and Tom Lane respectively.

Backpatch to 9.4 where these were introduced.

Branch
------
master

Details
-------
http://git.postgresql.org/pg/commitdiff/3c000fd9a68dae9ebd9d1507ab3995cc178de1e5

Modified Files
--------------
src/backend/utils/adt/jsonfuncs.c | 6 +++++-
1 file changed, 5 insertions(+), 1 deletion(-)

Browse pgsql-committers by date

  From Date Subject
Next Message Robert Haas 2015-05-04 17:00:22 pgsql: Backport "Expose fsync_fname as a public API".
Previous Message Tom Lane 2015-05-04 03:44:58 pgsql: Second try at fixing warnings caused by commit 9b43d73b3f9bef27.