From: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
---|---|
To: | Heikki Linnakangas <heikki(dot)linnakangas(at)enterprisedb(dot)com> |
Cc: | pgsql-hackers(at)postgreSQL(dot)org |
Subject: | Re: [BUGS] BUG #4680: Server crashed if using wrong (mismatch) conversion functions |
Date: | 2009-03-02 19:19:38 |
Message-ID: | 22078.1236021578@sss.pgh.pa.us |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-bugs pgsql-hackers |
I wrote:
> In any case, that's orthogonal to the part that I was focusing on,
> which was to try to prevent error recursion as a result of trouble
> in the encoding conversion subsystem. It looks like we could do that
> with some additional hacking in send_message_to_frontend() to avoid
> conversion, as well as translation, when in_error_recursion_trouble()
> is true. Your point about there possibly being non-ASCII user-inserted
> data in the message is a bit troubling, but for the cases where
> recursion is actually occurring I don't think that that will happen.
Here is a proposed patch that does this. It largely reverts my patch
of 2008-10-27 in favor of a more general policy that says that *all*
localization of error messages is disabled once we get into error
recursion trouble. Having done that, we can reasonably assume that
the error message text is 7-bit ASCII, and therefore bypass encoding
conversion as well. This fixes the example reported in bug #4680
(even without the subsequent patch to prevent that case from arising),
and it still prevents the cases that my previous patch was meant to
deal with.
Comments, objections?
regards, tom lane
Attachment | Content-Type | Size |
---|---|---|
unknown_filename | text/plain | 12.7 KB |
From | Date | Subject | |
---|---|---|---|
Next Message | Heikki Linnakangas | 2009-03-02 19:37:17 | Re: [BUGS] BUG #4680: Server crashed if using wrong (mismatch) conversion functions |
Previous Message | Tom Lane | 2009-03-02 17:21:43 | Re: BUG #4684: lastval in function |
From | Date | Subject | |
---|---|---|---|
Next Message | Greg Stark | 2009-03-02 19:31:48 | Re: regression test crashes at tsearch |
Previous Message | Teodor Sigaev | 2009-03-02 19:17:31 | Re: regression test crashes at tsearch |