Re: memory leak in ODBC driver - Mailing list pgsql-odbc

From Dave Page
Subject Re: memory leak in ODBC driver
Date
Msg-id E7F85A1B5FF8D44C8A1AF6885BC9A0E4527B5E@ratbert.vale-housing.co.uk
Whole thread Raw
In response to memory leak in ODBC driver  ("Scot Loach" <sloach@sandvine.com>)
List pgsql-odbc

> -----Original Message-----
> From: pgsql-odbc-owner@postgresql.org
> [mailto:pgsql-odbc-owner@postgresql.org] On Behalf Of Scot Loach
> Sent: 27 November 2004 18:11
> To: pgsql-odbc@postgresql.org
> Subject: [ODBC] memory leak in ODBC driver
>
> There is a 16-byte leak for every statement handle that has
> SQLFetch called on it.
> I have tracked this leak down to its source:
> SC_Fetch calls extend_getdata_info, which allocates memory
> for the stmt.getdata_info.
> However, this memory is never freed when the statement is deallocated.
>
> This patch seems to fix the problem - however I don't know
> enough about the internals of the driver to really understand
> if this is the correct or safe fix.
> Can one of the developers help me out here?

It certainly *looks* OK to me, but I share the same concerns as you
(I've never really got that far inside the driver before). Anyone else
care to comment?

Regards, Dave.

pgsql-odbc by date:

Previous
From: "Scot Loach"
Date:
Subject: memory leak in ODBC driver
Next
From: "Scot Loach"
Date:
Subject: Re: memory leak in ODBC driver