pgsql: Fix WAL-logging of B-tree "unlink halfdead page" operation.

Поиск
Список
Период
Сортировка
От Heikki Linnakangas
Тема pgsql: Fix WAL-logging of B-tree "unlink halfdead page" operation.
Дата
Msg-id E1XqPUL-0006QG-J5@gemulon.postgresql.org
обсуждение исходный текст
Список pgsql-committers
Fix WAL-logging of B-tree "unlink halfdead page" operation.

There was some confusion on how to record the case that the operation
unlinks the last non-leaf page in the branch being deleted.
_bt_unlink_halfdead_page set the "topdead" field in the WAL record to
the leaf page, but the redo routine assumed that it would be an invalid
block number in that case. This commit fixes _bt_unlink_halfdead_page to
do what the redo routine expected.

This code is new in 9.4, so backpatch there.

Branch
------
master

Details
-------
http://git.postgresql.org/pg/commitdiff/c73669c0e0168923e3f9e787beec980f55af2bd8

Modified Files
--------------
src/backend/access/nbtree/nbtpage.c |   13 ++++++-------
1 file changed, 6 insertions(+), 7 deletions(-)


В списке pgsql-committers по дате отправления:

Предыдущее
От: Alvaro Herrera
Дата:
Сообщение: pgsql: Fix relpersistence setting in reindex_index
Следующее
От: Heikki Linnakangas
Дата:
Сообщение: pgsql: Fix WAL-logging of B-tree "unlink halfdead page" operation.