File tree Expand file tree Collapse file tree 1 file changed +8
-3
lines changed Expand file tree Collapse file tree 1 file changed +8
-3
lines changed Original file line number Diff line number Diff line change 66 * Portions Copyright (c) 1996-2003, PostgreSQL Global Development Group
77 *
88 * IDENTIFICATION
9- * $PostgreSQL: pgsql/src/timezone/pgtz.c,v 1.12 2004/05/23 22:24:08 tgl Exp $
9+ * $PostgreSQL: pgsql/src/timezone/pgtz.c,v 1.13 2004/05/23 23:26:53 tgl Exp $
1010 *
1111 *-------------------------------------------------------------------------
1212 */
@@ -219,9 +219,14 @@ identify_system_timezone(void)
219219 if (try_timezone (__tzbuf , & tt , dst_found ))
220220 return __tzbuf ;
221221
222- /* Did not find the timezone. Fallback to try a GMT zone. */
222+ /*
223+ * Did not find the timezone. Fallback to try a GMT zone. Note that the
224+ * zic timezone database names the GMT-offset zones in POSIX style: plus
225+ * is west of Greenwich. It's unfortunate that this is opposite of SQL
226+ * conventions. Should we therefore change the names? Probably not...
227+ */
223228 sprintf (__tzbuf , "Etc/GMT%s%d" ,
224- (- tt .std_ofs < 0 ) ? "+" : "" , tt .std_ofs / 3600 );
229+ (- tt .std_ofs > 0 ) ? "+" : "" , - tt .std_ofs / 3600 );
225230 ereport (LOG ,
226231 (errmsg ("could not recognize system timezone, defaulting to \"%s\"" ,
227232 __tzbuf ),
You can’t perform that action at this time.
0 commit comments