Cleanup palloc'd structs on soft error path in `record_in`

Поиск
Список
Период
Сортировка
От Kirill Reshke
Тема Cleanup palloc'd structs on soft error path in `record_in`
Дата
Msg-id CALdSSPjaY86HX+MWOT28F05gE46AqeYFvAdp8qJgWQcPJ=gOHw@mail.gmail.com
обсуждение исходный текст
Список pgsql-hackers
Hi hackers!

I have been looking in coverity that runs against our PostgreSQL
fork(vanilla + our poor-man patches to be more cloud-native), and
spotted $subj.

Unlike many other reports, this looks like a real one to me?

Looks like after ccff2d20ed96, when we changed elog to ereport in a
number of places in this function, we now fail to release memory
allocated for one row. Now, PostgreSQL has REJECT_LIMIT feature, so
looks like this leak can aggregate in COPY scenarios

WDYT?

PFA trivial fix.


-- 
Best regards,
Kirill Reshke

Вложения

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