Re: scripts/common.c minor memory leak

From: Andrew Dunstan <andrew(at)dunslane(dot)net>
To: Martijn van Oosterhout <kleptog(at)svana(dot)org>
Cc: PostgreSQL Hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: scripts/common.c minor memory leak
Date: 2006-10-03 21:27:31
Message-ID: 4522D5C3.7000103@dunslane.net
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers pgsql-patches

Martijn van Oosterhout wrote:
> Just a minor thing. In yesno_prompt(), the value is resp is allocated
> memory that is never freed.
>
> File: src/bin/scripts/common.c
> Line: 218
>
> Not terribly important though, it's not used in critical utilities, but
> it's used often.
>
> Found by coverity.
>

It is surely not the only memory leak. We know there are some and in
most cases (like this) they aren't worth the trouble to clean up. If it
were used in psql or the backend I'd be worried, but it isn't, so I'm not.

cheers

andrew

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Jim C. Nasby 2006-10-03 21:35:48 timetz storage vs timestamptz
Previous Message Bruce Momjian 2006-10-03 21:25:58 Re: [HACKERS] Numeric overflow problem + patch

Browse pgsql-patches by date

  From Date Subject
Next Message Bruce Momjian 2006-10-03 21:46:56 Re: [HACKERS] scripts/common.c minor memory leak
Previous Message Bruce Momjian 2006-10-03 21:25:58 Re: [HACKERS] Numeric overflow problem + patch