From: | Martijn van Oosterhout <kleptog(at)svana(dot)org> |
---|---|
To: | Steve Crawford <scrawford(at)pinpointresearch(dot)com> |
Cc: | pgsql-general(at)postgresql(dot)org |
Subject: | Re: libpq and unwanted stderr output |
Date: | 2005-08-19 17:29:04 |
Message-ID: | 20050819172904.GE6226@svana.org |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-general |
On Fri, Aug 19, 2005 at 10:16:14AM -0700, Steve Crawford wrote:
> I have some C programs which use libpq and I do not want them to write
> output to the screen (unless, of course, I direct them to do so).
> When I use libpq I get unwanted messaged dumped to stderr.
I think you want these:
extern PQnoticeReceiver PQsetNoticeReceiver(PGconn *conn,
PQnoticeReceiver proc,
void *arg);
extern PQnoticeProcessor PQsetNoticeProcessor(PGconn *conn,
PQnoticeProcessor proc,
void *arg);
Not sure about the difference between the two, but just supressing them
should be easy.
--
Martijn van Oosterhout <kleptog(at)svana(dot)org> http://svana.org/kleptog/
> Patent. n. Genius is 5% inspiration and 95% perspiration. A patent is a
> tool for doing 5% of the work and then sitting around waiting for someone
> else to do the other 95% so you can sue them.
From | Date | Subject | |
---|---|---|---|
Next Message | Carlos Oliva | 2005-08-19 18:32:21 | Installing soundex, metaphone, lenshtein |
Previous Message | Adam Witney | 2005-08-19 17:27:14 | Re: How to cancel a query if SIGINT does not work? |