dblink memory leak - Mailing list pgsql-hackers

From Itagaki Takahiro
Subject dblink memory leak
Date
Msg-id 20091005113703.9CD9.52131E4D@oss.ntt.co.jp
Whole thread Raw
In response to Re: CommitFest 2009-09, two weeks on  (Joe Conway <mail@joeconway.com>)
Responses Re: dblink memory leak  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-hackers
Joe Conway <mail@joeconway.com> wrote:

> > The point is *memory leak* in dblink when a query is canceled or
> > become time-out. I think it is a bug, and my patch could fix it.
> 
> Please see if this works for you.

It does not work because errors can occur in caller of dblink functions;
Error callback should be still registered after SRF_RETURN_NEXT, so we
cannot place callback context on stack of the function. More works needed.

RegisterExprContextCallback() might be good for this purpose,
but we need to modify callbacks are fired even if error.

Regards,
---
ITAGAKI Takahiro
NTT Open Source Software Center




pgsql-hackers by date:

Previous
From: Itagaki Takahiro
Date:
Subject: Re: CREATE LIKE INCLUDING COMMENTS and STORAGES
Next
From: Robert Haas
Date:
Subject: Re: Rules: A Modest Proposal