Plug minor memleak in pg_dump - Mailing list pgsql-hackers

From gkokolatos@pm.me
Subject Plug minor memleak in pg_dump
Date
Msg-id oZwKiUxFsVaetG2xOJp7Hwao8F1AKIdfFDQLNJrnwoaxmjyB-45r_aYmhgXHKLcMI3GT24m9L6HafSi2ns7WFxXe0mw2_tIJpD-Z3vb_eyI=@pm.me
Whole thread Raw
Responses Re: Plug minor memleak in pg_dump
List pgsql-hackers
Hi,

I noticed a minor memleak in pg_dump. ReadStr() returns a malloc'ed pointer which
should then be freed. While reading the Table of Contents, it was called as an argument
within a function call, leading to a memleak.

Please accept the attached as a proposed fix.

Cheers,
//Georgios
Attachment

pgsql-hackers by date:

Previous
From: Dagfinn Ilmari Mannsåker
Date:
Subject: Re: Support tab completion for upper character inputs in psql
Next
From: Fujii Masao
Date:
Subject: Re: RFC: Logging plan of the running query