Subject Re: [ib-support] firebird api: who deallocs memory?
Author C R Zamana
On Thu, 2002-02-21 at 13:20, John Bellardo wrote:
> Hi,
>
> On Thursday, February 21, 2002, at 07:57 AM, C R Zamana wrote:
> >
> > Hi fellows,
> >
> > Below is an excerpt of my code. This function handles the
> > connection.
> >
> > The question is: who must free the dpb variable?
> >
> > I'm asking because when I try to free it my program
> > crashes, even if this free is called from the disconnection
> > function, after the disconnection.
> >
> > I'm worry about this because my daemon is eating memory,
> > even if all that is done by the client is just connect and disconnect.
> > As long as I could check this is the only piece of memory that I'm
> > not freeing explicitly.
> >
>
> I think your problem is the use of isc_expand_dpb. That function does
> not do what you expect, and is poorly documented AFAIK.
> (...)

Bingo! I use the example in the API docs to populate the dpb
buffer myself and now my memory is comeback :-)

Thank you.
Best regards.