1.2b19: _timezone on NT [patch]

From: Henrik Nordstrom <hno@dont-contact.us>
Date: Sun, 12 Apr 1998 20:14:00 +0200

This is a multi-part message in MIME format.

--------------7BE6C9AF15BF22D16ED381D
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit

* Squid-1.2.beta19: Use _timezone if defined (cygwin32)
     Use _timezone instead of timezone if defined. cygwin32 uses a
     macro called _timezone instead of the time_t variable timezone
     most else uses (timezone is a function in cygwin32).

After this patch the NT port seems to pass my basic tests. Maybe time
for public announce?

/Henrik

--------------7BE6C9AF15BF22D16ED381D
Content-Type: text/plain; charset=us-ascii; name="squid-1.2.beta19.timezone.patch"
Content-Transfer-Encoding: 7bit
Content-Disposition: inline; filename="squid-1.2.beta19.timezone.patch"

Index: squid/lib/rfc1123.c
diff -u squid/lib/rfc1123.c:1.1.1.8 squid/lib/rfc1123.c:1.1.1.8.4.1
--- squid/lib/rfc1123.c:1.1.1.8 Tue Mar 24 20:00:06 1998
+++ squid/lib/rfc1123.c Sun Apr 12 19:12:58 1998
@@ -258,7 +258,7 @@
     t = mktime(&tm);
     {
         time_t dst = 0;
-#ifndef _TIMEZONE
+#if !defined _TIMEZONE && !defined _timezone
         extern time_t timezone;
 #endif /* _TIMEZONE */
         /*
@@ -267,7 +267,11 @@
          */
         if (tm.tm_isdst > 0)
             dst = -3600;
+#ifdef _timezone
+ t -= (_timezone + dst);
+#else
         t -= (timezone + dst);
+#endif
     }
 #endif
     return t;

--------------7BE6C9AF15BF22D16ED381D--
Received on Tue Jul 29 2003 - 13:15:47 MDT

This archive was generated by hypermail pre-2.1.9 : Tue Dec 09 2003 - 16:11:45 MST