Обсуждение: It seems to miss PQclear function

Поиск
Список
Период
Сортировка

It seems to miss PQclear function

От
Quan Zongliang
Дата:
hi all

In ExecuteVoid function of pgConn class:
    // Check for errors
    if (lastResultStatus != PGRES_TUPLES_OK &&
        lastResultStatus != PGRES_COMMAND_OK)
    {
        LogError(!reportError);
        return false;
    }

Shoud be:
    // Check for errors
    if (lastResultStatus != PGRES_TUPLES_OK &&
        lastResultStatus != PGRES_COMMAND_OK)
    {
        LogError(!reportError);
        PQclear(qryRes);
        return false;
    }

right?


-----------------------------------------------
Quan Zongliang
quanzongliang@gmail.com

Вложения

Re: It seems to miss PQclear function

От
Dave Page
Дата:
Yup, looks that way. Patch applied.

Thanks!

On Tue, Sep 15, 2009 at 6:08 AM, Quan Zongliang <quanzongliang@gmail.com> wrote:
> hi all
>
> In ExecuteVoid function of pgConn class:
>    // Check for errors
>    if (lastResultStatus != PGRES_TUPLES_OK &&
>        lastResultStatus != PGRES_COMMAND_OK)
>    {
>        LogError(!reportError);
>        return false;
>    }
>
> Shoud be:
>    // Check for errors
>    if (lastResultStatus != PGRES_TUPLES_OK &&
>        lastResultStatus != PGRES_COMMAND_OK)
>    {
>        LogError(!reportError);
>        PQclear(qryRes);
>        return false;
>    }
>
> right?
>
>
> -----------------------------------------------
> Quan Zongliang
> quanzongliang@gmail.com
>
>
> --
> Sent via pgadmin-hackers mailing list (pgadmin-hackers@postgresql.org)
> To make changes to your subscription:
> http://www.postgresql.org/mailpref/pgadmin-hackers
>
>



--
Dave Page
EnterpriseDB UK:   http://www.enterprisedb.com