]> granicus.if.org Git - postgresql/commitdiff
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:29 +0000 (18:54 +0300)
My previous back-patching went wrong.

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

index 365e7525d74a151ae3abfff936a4f67520f27c14..fce0bb9b364b1ef514d18b038b1929e3a86abf18 100644 (file)
@@ -953,7 +953,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 78ad5ddd9b7211788d0a854fad0ca7a87cbae5cc..44d27b623e12a9648f5e575abf9fbe97b149681b 100644 (file)
@@ -887,7 +887,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