memory leak in ODBC driver

Поиск
Список
Период
Сортировка
От Scot Loach
Тема memory leak in ODBC driver
Дата
Msg-id DF02F5FE21007A44B8464101EFA761EF255AA8@exchange.sandvine.com
обсуждение исходный текст
Список pgsql-odbc
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
understandif this is the correct or safe fix. 
Can one of the developers help me out here?

--- statement.c.old     2004-11-27 13:07:57.000000000 -0500
+++ statement.c 2004-11-27 13:09:37.000000000 -0500
@@ -354,6 +354,8 @@
        if (self->callbacks)
                free(self->callbacks);

+        GDATA_unbind_cols(SC_get_GDTI(self), TRUE);
+
        DELETE_STMT_CS(self);
        free(self);

В списке pgsql-odbc по дате отправления:

Предыдущее
От: Amir Zicherman
Дата:
Сообщение: autocommit off
Следующее
От: "Dave Page"
Дата:
Сообщение: Re: memory leak in ODBC driver