Re: Memory-leak in BackgroundWriter(and Checkpointer) - Mailing list pgsql-bugs

From Stephen Frost
Subject Re: Memory-leak in BackgroundWriter(and Checkpointer)
Date
Msg-id 20130604180229.GJ5871@tamriel.snowman.net
Whole thread Raw
In response to Re: Memory-leak in BackgroundWriter(and Checkpointer)  (Andres Freund <andres@2ndquadrant.com>)
List pgsql-bugs
* Andres Freund (andres@2ndquadrant.com) wrote:
> Seems more consistent with the rest of the code too. But anyway, I am
> fine with fixing it either way.

Patch attached which mirrors what GetRunningTransactionData() (the other
function called from LogStandbySnapshot) does, more-or-less- uses a
static variable to keep track of memory allocated for the data being
returned to the caller.

Looks like this will need to be back-patched to 9.0.  Barring objections
or better ideas, I'll do that in a few hours.

    Thanks,

        Stephen

Attachment

pgsql-bugs by date:

Previous
From: Tom Lane
Date:
Subject: Re: Memory-leak in BackgroundWriter(and Checkpointer)
Next
From: Stephen Frost
Date:
Subject: Re: Memory-leak in BackgroundWriter(and Checkpointer)