Re: Small psql memory fix

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Bruce Momjian <bruce(at)momjian(dot)us>
Cc: PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Small psql memory fix
Date: 2014-02-15 04:28:49
Message-ID: 511.1392438529@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Bruce Momjian <bruce(at)momjian(dot)us> writes:
> The attached tiny patch fixes a small leak in psql's \gset command and
> simplifies memory freeing in two places.

The first and third hunks look to me like they introduce memory
leaks, not fix them. The second hunk is probably safe enough,
although I'm not sure the case can actually occur --- gset should
free the prefix before any new backslash command can be executed.

regards, tom lane

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Bruce Momjian 2014-02-15 04:35:08 Re: Small psql memory fix
Previous Message Robert Haas 2014-02-15 04:03:43 Re: Patch: show xid and xmin in pg_stat_activity and pg_stat_replication