Re: libpq ssl -> clear fallback looses error messages

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Magnus Hagander <magnus(at)hagander(dot)net>
Cc: PG Hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: libpq ssl -> clear fallback looses error messages
Date: 2008-10-12 00:42:31
Message-ID: 1085.1223772151@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Magnus Hagander <magnus(at)hagander(dot)net> writes:
> Here's an ugly attempt towards this. Though I'm unsure if we can change
> the "const" on the PQerrorMessage parameter without messing with library
> versions and such?

That's a bad idea in any case --- PQerrorMessage shouldn't be changing
the state of anything. The merging needs to happen earlier.

> Another option could be to change all the calls that set the error
> message to *append* to the error message instead. Thoughts on that?

That might work ... but we'd probably have to add some "clear the
message" calls in places. It might be worth trying to restrict this
convention to the connection-startup code.

regards, tom lane

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Gregory Stark 2008-10-12 00:43:40 Re: recursive query crash
Previous Message Gregory Stark 2008-10-12 00:26:29 Re: Buffer pool statistics in Explain Analyze