pgsql: Fix use of dangling pointer in heap_delete() when loggingreplic

Поиск
Список
Период
Сортировка
От Michael Paquier
Тема pgsql: Fix use of dangling pointer in heap_delete() when loggingreplic
Дата
Msg-id E1gpNmk-00028k-R3@gemulon.postgresql.org
обсуждение исходный текст
Список pgsql-committers
Fix use of dangling pointer in heap_delete() when logging replica identity

When logging the replica identity of a deleted tuple, XLOG_HEAP_DELETE
records include references of the old tuple.  Its data is stored in an
intermediate variable used to register this information for the WAL
record, but this variable gets away from the stack when the record gets
actually inserted.

Spotted by clang's AddressSanitizer.

Author: Stas Kelvish
Discussion: https://postgr.es/m/085C8825-AD86-4E93-AF80-E26CDF03D1EA@postgrespro.ru
Backpatch-through: 9.4

Branch
------
REL9_6_STABLE

Details
-------
https://git.postgresql.org/pg/commitdiff/014763e97668d1597d3cc2abe9ec4bdbf1554e5f

Modified Files
--------------
src/backend/access/heap/heapam.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)


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

Предыдущее
От: Peter Eisentraut
Дата:
Сообщение: pgsql: Add more columns to pg_stat_ssl
Следующее
От: Michael Paquier
Дата:
Сообщение: pgsql: Adjust comment about timeout when waiting for WAL at recovery