Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
Oops, PQExpBufferDataBroken doesn't exist before 9.2.
authorHeikki Linnakangas <heikki.linnakangas@iki.fi>
Tue, 7 Jul 2015 15:54:08 +0000 (18:54 +0300)
committerHeikki Linnakangas <heikki.linnakangas@iki.fi>
Tue, 7 Jul 2015 15:54:08 +0000 (18:54 +0300)
My previous back-patching went wrong.

src/interfaces/libpq/fe-protocol2.c
src/interfaces/libpq/fe-protocol3.c

index 6824b6d6bc083dacfdb481be316d38667fd3f08d..3ace6a6290a25d2f3db02092437c617fe704fe6d 100644 (file)
@@ -888,7 +888,7 @@ pqGetErrorNotice2(PGconn *conn, bool isError)
        pqClearAsyncResult(conn);
        conn->result = res;
        resetPQExpBuffer(&conn->errorMessage);
-       if (res && !PQExpBufferDataBroken(workBuf) && res->errMsg)
+       if (res && !PQExpBufferBroken(&workBuf) && res->errMsg)
            appendPQExpBufferStr(&conn->errorMessage, res->errMsg);
        else
            printfPQExpBuffer(&conn->errorMessage,
index e314ab0a5269a65634c8ae90b4dba2ce3f318c8b..850d84d5abd8dc2c936751285d8294d5cbc4a124 100644 (file)
@@ -877,7 +877,7 @@ pqGetErrorNotice3(PGconn *conn, bool isError)
            res->errMsg = pqResultStrdup(res, workBuf.data);
        pqClearAsyncResult(conn);
        conn->result = res;
-       if (PQExpBufferDataBroken(workBuf))
+       if (PQExpBufferBroken(&workBuf))
            printfPQExpBuffer(&conn->errorMessage,
                              libpq_gettext("out of memory"));
        else