Skip to content

Commit 80bbfe7

Browse files
committed
Inlined a patch to add the libpq setNoticeProcessor capability to
libpq++. Ofir Reichenberg
1 parent 9f9e3c9 commit 80bbfe7

File tree

2 files changed

+9
-2
lines changed

2 files changed

+9
-2
lines changed

src/interfaces/libpq++/pgconnection.cc

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
* Copyright (c) 1994, Regents of the University of California
1111
*
1212
* IDENTIFICATION
13-
* $Header: /cvsroot/pgsql/src/interfaces/libpq++/Attic/pgconnection.cc,v 1.12 2001/09/30 22:30:37 tgl Exp $
13+
* $Header: /cvsroot/pgsql/src/interfaces/libpq++/Attic/pgconnection.cc,v 1.13 2002/03/11 15:08:18 momjian Exp $
1414
*
1515
*-------------------------------------------------------------------------
1616
*/
@@ -159,4 +159,8 @@ const char* PgConnection::DBName() const
159159
return (const char *)PQdb(pgConn);
160160
}
161161

162+
PQnoticeProcessor PgConnection::SetNoticeProcessor(PQnoticeProcessor proc, void *arg)
163+
{
164+
return PQsetNoticeProcessor(pgConn, proc, arg);
165+
}
162166

src/interfaces/libpq++/pgconnection.h

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
* Portions Copyright (c) 1996-2001, PostgreSQL Global Development Group
1414
* Portions Copyright (c) 1994, Regents of the University of California
1515
*
16-
* $Id: pgconnection.h,v 1.15 2002/01/22 19:02:40 tgl Exp $
16+
* $Id: pgconnection.h,v 1.16 2002/03/11 15:08:18 momjian Exp $
1717
*
1818
*-------------------------------------------------------------------------
1919
*/
@@ -80,6 +80,9 @@ class DLLIMPORT PgConnection {
8080
int ExecTuplesOk(const char* query); // send a command and check if tuples are returned
8181
PGnotify* Notifies();
8282

83+
// set the notice processor
84+
PQnoticeProcessor SetNoticeProcessor(PQnoticeProcessor proc, void *arg);
85+
8386
protected:
8487
ConnStatusType Connect(const char* conninfo);
8588
void CloseConnection();

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy