*
*
* IDENTIFICATION
- * $PostgreSQL: pgsql/src/backend/utils/error/elog.c,v 1.140 2004/06/03 02:08:04 tgl Exp $
+ * $PostgreSQL: pgsql/src/backend/utils/error/elog.c,v 1.141 2004/06/21 14:12:38 tgl Exp $
*
*-------------------------------------------------------------------------
*/
break;
case 't':
{
+ /*
+ * Note: for %t and %s we deliberately use the C library's
+ * strftime/localtime, and not the equivalent functions
+ * from src/timezone. This ensures that all backends
+ * will report log entries in the same timezone, namely
+ * whatever C-library setting they inherit from the
+ * postmaster. If we used src/timezone then local
+ * settings of the TimeZone GUC variable would confuse
+ * the log.
+ */
time_t stamp_time = time(NULL);
char strfbuf[128];