Fixes for a couple of resource leaks

Поиск
Список
Период
Сортировка
От Michael Paquier
Тема Fixes for a couple of resource leaks
Дата
Msg-id CAB7nPqQueXppg0CzSHPyF_5x9Nfii4dSCZtMsizPzc2xeB4qoA@mail.gmail.com
обсуждение исходный текст
Ответы Re: Fixes for a couple of resource leaks  (Tom Lane <tgl@sss.pgh.pa.us>)
Список pgsql-hackers
Hi all,

Coverity is pointing out a couple of resource leaks:
- In DropReplicationSlot@streamutil.c, query is leaked.
- In getTransforms@pg_dump.c, the alloced result of get_language_name is not free'd. Other code paths calling this routine do the job.
- In libpqGetCurrentXlogInsertLocation@libpq_fetch.c (pg_rewind), the value "val" returned by run_simple_query should be free'd. Other code paths do so.
- In libpqProcessFileList@libpq_fetch.c, a call to PQclear is missing for a query result.
- In vacuum_one_database@vacuumdb.c, a call to PQclear is missing.
Attached is a patch to address all those things. Backpatches would be good to have as well.
Regards,
--
Michael
Вложения

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

Предыдущее
От: Michael Paquier
Дата:
Сообщение: Re: Re: Removing SSL renegotiation (Was: Should we back-patch SSL renegotiation fixes?)
Следующее
От: Tom Lane
Дата:
Сообщение: TABLESAMPLE doesn't actually satisfy the SQL spec, does it?