Re: Log line prefix on win32 - Mailing list pgsql-hackers

From Tom Lane
Subject Re: Log line prefix on win32
Date
Msg-id 13735.1097254211@sss.pgh.pa.us
Whole thread Raw
In response to Re: Log line prefix on win32  (Bruce Momjian <pgman@candle.pha.pa.us>)
Responses Re: Log line prefix on win32
List pgsql-hackers
Bruce Momjian <pgman@candle.pha.pa.us> writes:
> I am still trying to figure out a good way to fix this.  On unix my log
> shows EDT but Win32 shows US/Eastern and some zones are much longer.
> Should we add %z and not print the timezone information for %t?  That
> seems like the only reasonable solution.

%z is not standard --- you won't find it in the SUS spec for instance.
Or were you thinking of exposing this problem at the API level by making
people write a separate log_line_prefix item to get the timezone?  I'm
not thrilled about institutionalizing such a fix for a platform-specific
issue that might go away later (if we switch to using our own timezone
code here, for instance).

I'd be inclined to #ifdef elog's strftime calls so that the zone is
omitted on Windows but not elsewhere.  Kinda ugly but it's a localized
fix that we can easily improve later.
        regards, tom lane


pgsql-hackers by date:

Previous
From: Andrew Dunstan
Date:
Subject: Re: Log line prefix on win32
Next
From: Josh Berkus
Date:
Subject: Re: plans for bitmap indexes?