Re: [PATCH] Make gram.y use palloc/pfree for memory management

From: "Marko Kreen" <markokr(at)gmail(dot)com>
To: "Tom Lane" <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: pgsql-hackers(at)postgresql(dot)org
Subject: Re: [PATCH] Make gram.y use palloc/pfree for memory management
Date: 2008-09-02 10:29:58
Message-ID: e51f66da0809020329x2eb85e55g70e8b5d1cf7ed577@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On 9/1/08, Marko Kreen <markokr(at)gmail(dot)com> wrote:
> First a correction, overriding malloc/free seems dangerous they
> seems to leak out, so correct would be to use YYMALLOC/YYFREE.
> This leaves 1.875 potentially leaking, but danger seems small.

Here is the safer patch. As the chance for the leak is rare,
leaving 1.875 vulnerable should not be problem.

--
marko

Attachment Content-Type Size
bison.palloc.diff text/x-diff 477 bytes

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Heikki Linnakangas 2008-09-02 10:38:20 Re: rmgr hooks and contrib/rmgr_hook
Previous Message Martijn van Oosterhout 2008-09-02 10:24:21 Re: Window functions patch v04 for the September commit fest