From: | Fujii Masao <fujii(at)postgresql(dot)org> |
---|---|
To: | pgsql-committers(at)postgresql(dot)org |
Subject: | pgsql: Fix incorrect output from gin_desc(). |
Date: | 2016-12-05 11:32:20 |
Message-ID: | E1cDrVM-0002K5-UJ@gemulon.postgresql.org |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-committers |
Fix incorrect output from gin_desc().
Previously gin_desc() displayed incorrect output "unknown action 0"
for XLOG_GIN_INSERT and XLOG_GIN_VACUUM_DATA_LEAF_PAGE records with
valid actions. The cause of this problem was that gin_desc() wrongly
used XLogRecGetData() to extract data from those records.
Since they were registered by XLogRegisterBufData(), gin_desc() should
have used XLogRecGetBlockData(), instead, like gin_redo().
Also there were other differences about how to treat XLOG_GIN_INSERT
record between gin_desc() and gin_redo().
This commit fixes gin_desc() routine so that it treats those records
in the same way as gin_redo().
Batch-patch to 9.5 where WAL record format was revamped and
XLogRegisterBufData() was added.
Reported-By: Andres Freund
Reviewed-By: Tom Lane
Discussion: <20160509194645(dot)7lewnpw647zegx2m(at)alap3(dot)anarazel(dot)de>
Branch
------
master
Details
-------
http://git.postgresql.org/pg/commitdiff/5dc851afde8d9ef9947f21799f7a1b08bf0bf812
Modified Files
--------------
src/backend/access/rmgrdesc/gindesc.c | 45 +++++++++++++++++++----------------
1 file changed, 24 insertions(+), 21 deletions(-)
From | Date | Subject | |
---|---|---|---|
Next Message | Heikki Linnakangas | 2016-12-05 11:44:37 | pgsql: Replace PostmasterRandom() with a stronger source, second attemp |
Previous Message | Michael Paquier | 2016-12-05 01:24:56 | Re: pgsql: Add putenv support for msvcrt from Visual Studio 2013 |