mirror of
https://github.com/postgres/postgres.git
synced 2025-06-25 01:02:05 +03:00
Fix the various forms of AT TIME ZONE to accept either timezones found
in the zic database or zone names found in the date token table. This preserves the old ability to do AT TIME ZONE 'PST' along with the new ability to do AT TIME ZONE 'PST8PDT'. Per gripe from Bricklen Anderson. Also, fix some inconsistencies in usage of TZ_STRLEN_MAX --- the old code had the potential for one-byte buffer overruns, though given alignment considerations it's unlikely there was any real risk.
This commit is contained in:
@ -6,7 +6,7 @@
|
||||
* Portions Copyright (c) 1996-2005, PostgreSQL Global Development Group
|
||||
*
|
||||
* IDENTIFICATION
|
||||
* $PostgreSQL: pgsql/src/include/pgtime.h,v 1.9 2005/07/22 03:46:34 momjian Exp $
|
||||
* $PostgreSQL: pgsql/src/include/pgtime.h,v 1.10 2005/09/09 02:31:49 tgl Exp $
|
||||
*
|
||||
*-------------------------------------------------------------------------
|
||||
*/
|
||||
@ -58,7 +58,7 @@ extern const char *pg_get_timezone_name(pg_tz *tz);
|
||||
|
||||
extern pg_tz *global_timezone;
|
||||
|
||||
/* Maximum length of a timezone name */
|
||||
/* Maximum length of a timezone name (not including trailing null) */
|
||||
#define TZ_STRLEN_MAX 255
|
||||
|
||||
#endif /* _PGTIME_H */
|
||||
|
Reference in New Issue
Block a user