pgsql: Check syscache result in AlterStatistics

Поиск
Список
Период
Сортировка
От Tomas Vondra
Тема pgsql: Check syscache result in AlterStatistics
Дата
Msg-id E1nBTHu-0008PW-0Z@gemulon.postgresql.org
обсуждение исходный текст
Список pgsql-committers
Check syscache result in AlterStatistics

The syscache lookup may return NULL even for valid OID, for example due
to a concurrent DROP STATISTICS, so a HeapTupleIsValid is necessary.
Without it, it may fail with a segfault.

Reported by Alexander Lakhin, patch by me. Backpatch to 13, where ALTER
STATISTICS ... SET STATISTICS was introduced.

Backpatch-through: 13
Discussion: https://postgr.es/m/17372-bf3b6e947e35ae77%40postgresql.org

Branch
------
REL_14_STABLE

Details
-------
https://git.postgresql.org/pg/commitdiff/a192243c75be0f142f829b3e73548bc7cbd3b90d

Modified Files
--------------
src/backend/commands/statscmds.c | 2 ++
1 file changed, 2 insertions(+)


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

Предыдущее
От: Tomas Vondra
Дата:
Сообщение: pgsql: Correct type of front_pathkey to PathKey
Следующее
От: Tomas Vondra
Дата:
Сообщение: pgsql: Correct type of front_pathkey to PathKey