pg.ddx.io pgsql-committers@postgresql.org mailing list archivehelp / color / mirror / Atom feed
pgsql: Don't call PageGetSpecialPointer() on page until it's been initi 2+ messages / 1 participants [nested] [flat]
* pgsql: Don't call PageGetSpecialPointer() on page until it's been initi @ 2015-06-30 10:49 Heikki Linnakangas <heikki.linnakangas@iki.fi> 0 siblings, 0 replies; 2+ messages in thread From: Heikki Linnakangas @ 2015-06-30 10:49 UTC (permalink / raw) To: pgsql-committers Don't call PageGetSpecialPointer() on page until it's been initialized. After calling XLogInitBufferForRedo(), the page might be all-zeros if it was not in page cache already. btree_xlog_unlink_page initialized the page correctly, but it called PageGetSpecialPointer before initializing it, which would lead to a corrupt page at WAL replay, if the unlinked page is not in page cache. Backpatch to 9.4, the bug came with the rewrite of B-tree page deletion. Branch ------ master Details ------- http://git.postgresql.org/pg/commitdiff/fdf28853ae6a397497b79fea69f89f4f7b9aa991 Modified Files -------------- src/backend/access/nbtree/nbtxlog.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) -- Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-committers ^ permalink raw reply [nested|flat] 2+ messages in thread
* pgsql: Don't call PageGetSpecialPointer() on page until it's been initi @ 2015-06-30 10:49 Heikki Linnakangas <heikki.linnakangas@iki.fi> 0 siblings, 0 replies; 2+ messages in thread From: Heikki Linnakangas @ 2015-06-30 10:49 UTC (permalink / raw) To: pgsql-committers Don't call PageGetSpecialPointer() on page until it's been initialized. After calling XLogInitBufferForRedo(), the page might be all-zeros if it was not in page cache already. btree_xlog_unlink_page initialized the page correctly, but it called PageGetSpecialPointer before initializing it, which would lead to a corrupt page at WAL replay, if the unlinked page is not in page cache. Backpatch to 9.4, the bug came with the rewrite of B-tree page deletion. Branch ------ REL9_4_STABLE Details ------- http://git.postgresql.org/pg/commitdiff/7dc721889b31450cad338a189a97ff0ff46534d5 Modified Files -------------- src/backend/access/nbtree/nbtxlog.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) -- Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-committers ^ permalink raw reply [nested|flat] 2+ messages in thread
end of thread, other threads:[~2015-06-30 10:49 UTC | newest] Thread overview: 2+ messages (download: mbox mbox.gz follow: Atom feed) -- links below jump to the message on this page -- 2015-06-30 10:49 pgsql: Don't call PageGetSpecialPointer() on page until it's been initi Heikki Linnakangas <heikki.linnakangas@iki.fi> 2015-06-30 10:49 pgsql: Don't call PageGetSpecialPointer() on page until it's been initi Heikki Linnakangas <heikki.linnakangas@iki.fi>
This inbox is served by DDX for PostgreSQL; see mirroring instructions for how to clone and mirror all data and code used for this inbox