diff options
author | Tom Lane <tgl@sss.pgh.pa.us> | 2003-06-23 19:20:25 +0000 |
---|---|---|
committer | Tom Lane <tgl@sss.pgh.pa.us> | 2003-06-23 19:20:25 +0000 |
commit | ab5c775116413b1b7fb09cd83bfcc242d8756601 (patch) | |
tree | 32eec15b275af2398caa1ee1a6d876c713e18252 /src/interfaces/libpq/fe-connect.c | |
parent | 408625321c8e6bf387f91c2112e30fd64d28a4b8 (diff) | |
download | postgresql-ab5c775116413b1b7fb09cd83bfcc242d8756601.tar.gz postgresql-ab5c775116413b1b7fb09cd83bfcc242d8756601.zip |
Change pqInternalNotice to accept a format string and args instead of
just a preformatted message; per suggestion by Sean Chittenden.
Diffstat (limited to 'src/interfaces/libpq/fe-connect.c')
-rw-r--r-- | src/interfaces/libpq/fe-connect.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/src/interfaces/libpq/fe-connect.c b/src/interfaces/libpq/fe-connect.c index b44d2fd068d..a931fe9fa24 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.251 2003/06/23 17:03:19 momjian Exp $ + * $Header: /cvsroot/pgsql/src/interfaces/libpq/fe-connect.c,v 1.252 2003/06/23 19:20:24 tgl Exp $ * *------------------------------------------------------------------------- */ @@ -2843,8 +2843,9 @@ static void defaultNoticeReceiver(void *arg, const PGresult *res) { (void) arg; /* not used */ - (*res->noticeHooks.noticeProc) (res->noticeHooks.noticeProcArg, - PQresultErrorMessage(res)); + if (res->noticeHooks.noticeProc != NULL) + (*res->noticeHooks.noticeProc) (res->noticeHooks.noticeProcArg, + PQresultErrorMessage(res)); } /* |