Re: BUG #7493: Postmaster messages unreadable in a Windows console - Mailing list pgsql-hackers

From Noah Misch
Subject Re: BUG #7493: Postmaster messages unreadable in a Windows console
Date
Msg-id 20130130015155.GD3524@tornado.leadboat.com
Whole thread Raw
In response to Re: BUG #7493: Postmaster messages unreadable in a Windows console  (Tom Lane <tgl@sss.pgh.pa.us>)
Responses Re: BUG #7493: Postmaster messages unreadable in a Windows console
List pgsql-hackers
On Tue, Jan 29, 2013 at 09:54:04AM -0500, Tom Lane wrote:
> Alexander Law <exclusion@gmail.com> writes:
> > Please look at the following l10n bug:
> > http://www.postgresql.org/message-id/502A26F1.6010109@gmail.com
> > and the proposed patch.
> 
> That patch looks entirely unsafe to me.  Neither of those functions
> should be expected to be able to run when none of our standard
> infrastructure (palloc, elog) is up yet.
> 
> Possibly it would be safe to do this somewhere around where we do
> GUC initialization.

Even then, I wouldn't be surprised to find problematic consequences beyond
error display.  What if all the databases are EUC_JP, the platform encoding is
KOI8, and some postgresql.conf settings contain EUC_JP characters?  Does the
postmaster not rely on its use of SQL_ASCII to allow those values?

I would look at fixing this by making the error output machinery smarter in
this area before changing the postmaster's notion of server_encoding.



pgsql-hackers by date:

Previous
From: Noah Misch
Date:
Subject: Re: COPY FREEZE has no warning
Next
From: Noah Misch
Date:
Subject: Re: lazy_vacuum_heap()'s removal of HEAPTUPLE_DEAD tuples