pgsql: Ensure that slots are zeroed before use

Поиск
Список
Период
Сортировка
От Daniel Gustafsson
Тема pgsql: Ensure that slots are zeroed before use
Дата
Msg-id E1mfI4x-0006bi-R0@gemulon.postgresql.org
обсуждение исходный текст
Список pgsql-committers
Ensure that slots are zeroed before use

The previous coding relied on the memory for the slots being zeroed
elsewhere, which while it was true in this case is not an contract
which is guaranteed to hold.  Explicitly clear the tts_isnull array
to ensure that the slots are filled from a known state.

Backpatch to v14 where the catalog multi-inserts were introduced.

Reviewed-by: Michael Paquier <michael@paquier.xyz>
Discussion: https://postgr.es/m/CAJ7c6TP0AowkUgNL6zcAK-s5HYsVHVBRWfu69FRubPpfwZGM9A@mail.gmail.com
Backpatch-through: 14

Branch
------
REL_14_STABLE

Details
-------
https://git.postgresql.org/pg/commitdiff/1ed1f801cdd114822a5f08409f23a7f22be0b9fb

Modified Files
--------------
src/backend/catalog/heap.c        | 3 +++
src/backend/catalog/pg_shdepend.c | 3 +++
2 files changed, 6 insertions(+)


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

Предыдущее
От: Daniel Gustafsson
Дата:
Сообщение: pgsql: Ensure that slots are zeroed before use
Следующее
От: Fujii Masao
Дата:
Сообщение: pgsql: Improve HINT message that FDW reports when there are no valid op