pgsql: Fix under-parenthesized XLogRecHasBlockRef() macro.

Поиск
Список
Период
Сортировка
От Tom Lane
Тема pgsql: Fix under-parenthesized XLogRecHasBlockRef() macro.
Дата
Msg-id E1lYxVY-000553-Lm@gemulon.postgresql.org
обсуждение исходный текст
Список pgsql-committers
Fix under-parenthesized XLogRecHasBlockRef() macro.

Commit f003d9f87 left this macro with inadequate (or, one could say,
too much) parenthesization.  Which was catastrophic to the correctness
of calls such as "if (!XLogRecHasBlockRef(record, 1)) ...".  There
are only a few of those, which perhaps explains why we didn't notice
immediately (with our general weakness of WAL replay testing being
another factor).  I found it by debugging intermittent replay failures
like

2021-04-08 14:33:30.191 EDT [29463] PANIC:  failed to locate backup block with ID 1
2021-04-08 14:33:30.191 EDT [29463] CONTEXT:  WAL redo at 0/95D3438 for SPGist/ADD_NODE: off 1; blkref #0: rel
1663/16384/25998,blk 1 

Branch
------
master

Details
-------
https://git.postgresql.org/pg/commitdiff/9e41148229192dccc4bcc40f53af588b73d8ffea

Modified Files
--------------
src/include/access/xlogreader.h | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)


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

Предыдущее
От: Bruce Momjian
Дата:
Сообщение: pgsql: Fix interaction of log_line_prefix's query_id and log_statement
Следующее
От: Michael Paquier
Дата:
Сообщение: pgsql: Add CURRENT_ROLE to list of roles for tab completion of GRANT in