* Portions Copyright (c) 1996-2004, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
- * $PostgreSQL: pgsql/src/include/port.h,v 1.58 2004/09/08 19:43:07 momjian Exp $
+ * $PostgreSQL: pgsql/src/include/port.h,v 1.59 2004/09/09 00:24:10 momjian Exp $
*
*-------------------------------------------------------------------------
*/
/* Global variable holding time zone information. */
#if !defined(__CYGWIN__)
#define TIMEZONE_GLOBAL timezone
+#define TZNAME_GLOBAL tzname
#else
#define TIMEZONE_GLOBAL _timezone
-#define tzname _tzname /* should be in time.h? */
+#define TZNAME_GLOBAL _tzname
#endif
extern int copydir(char *fromdir, char *todir);
* case it contains an error message, which doesn't fit in the
* buffer
*/
- StrNCpy(*tzn, tzname[tm->tm_isdst], MAXTZLEN + 1);
- if (strlen(tzname[tm->tm_isdst]) > MAXTZLEN)
+ StrNCpy(*tzn, TZNAME_GLOBAL[tm->tm_isdst], MAXTZLEN + 1);
+ if (strlen(TZNAME_GLOBAL[tm->tm_isdst]) > MAXTZLEN)
tm->tm_isdst = -1;
}
}
#elif defined(HAVE_INT_TIMEZONE)
*tzp = ((tm->tm_isdst > 0) ? (TIMEZONE_GLOBAL - 3600) : TIMEZONE_GLOBAL);
if (tzn != NULL)
- *tzn = tzname[(tm->tm_isdst > 0)];
+ *tzn = TZNAME_GLOBAL[(tm->tm_isdst > 0)];
#endif
#else /* not (HAVE_TM_ZONE || HAVE_INT_TIMEZONE) */