From f690920a752fa8e59dc9536dd14194b2141163d2 Mon Sep 17 00:00:00 2001 From: Tom Lane Date: Thu, 24 Apr 2003 21:16:45 +0000 Subject: Infrastructure for upgraded error reporting mechanism. elog.c is rewritten and the protocol is changed, but most elog calls are still elog calls. Also, we need to contemplate mechanisms for controlling all this functionality --- eg, how much stuff should appear in the postmaster log? And what API should libpq expose for it? --- src/interfaces/libpq/fe-connect.c | 11 ++--------- 1 file changed, 2 insertions(+), 9 deletions(-) (limited to 'src/interfaces/libpq/fe-connect.c') diff --git a/src/interfaces/libpq/fe-connect.c b/src/interfaces/libpq/fe-connect.c index 086462094f..6ee2716ec0 100644 --- a/src/interfaces/libpq/fe-connect.c +++ b/src/interfaces/libpq/fe-connect.c @@ -8,7 +8,7 @@ * * * IDENTIFICATION - * $Header: /cvsroot/pgsql/src/interfaces/libpq/fe-connect.c,v 1.234 2003/04/22 00:08:07 tgl Exp $ + * $Header: /cvsroot/pgsql/src/interfaces/libpq/fe-connect.c,v 1.235 2003/04/24 21:16:44 tgl Exp $ * *------------------------------------------------------------------------- */ @@ -1429,20 +1429,13 @@ keep_going: /* We will come back to here until there /* Handle errors. */ if (beresp == 'E') { - if (pqGets(&conn->errorMessage, conn)) + if (pqGetErrorNotice(conn, true)) { /* We'll come back when there is more data */ return PGRES_POLLING_READING; } /* OK, we read the message; mark data consumed */ conn->inStart = conn->inCursor; - - /* - * The postmaster typically won't end its message with - * a newline, so add one to conform to libpq - * conventions. - */ - appendPQExpBufferChar(&conn->errorMessage, '\n'); goto error_return; } -- cgit v1.2.1