From: wessels <> Date: Fri, 24 Apr 1998 11:20:23 +0000 (+0000) Subject: windows NT defines _timezone apparently X-Git-Tag: SQUID_3_0_PRE1~3439 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=9b6dbb2a6e8c2a686cbf7ff2a06cd1b75f02c70d;p=thirdparty%2Fsquid.git windows NT defines _timezone apparently --- diff --git a/lib/rfc1123.c b/lib/rfc1123.c index bb9d179e58..5fc2d4f87d 100644 --- a/lib/rfc1123.c +++ b/lib/rfc1123.c @@ -1,6 +1,6 @@ /* - * $Id: rfc1123.c,v 1.16 1998/04/21 22:43:44 wessels Exp $ + * $Id: rfc1123.c,v 1.17 1998/04/24 05:20:23 wessels Exp $ * * DEBUG: * AUTHOR: Harvest Derived @@ -251,16 +251,20 @@ parse_rfc1123(const char *str) t = mktime(&tm); { time_t dst = 0; -#ifndef _TIMEZONE +#if !defined _TIMEZONE && !defined _timezone extern time_t timezone; -#endif /* _TIMEZONE */ +#endif /* * The following assumes a fixed DST offset of 1 hour, * which is probably wrong. */ if (tm.tm_isdst > 0) dst = -3600; +#ifdef _timezone + t -= (_timezone + dst); +#else t -= (timezone + dst); +#endif } #endif return t;