This is the mail archive of the libc-alpha@cygnus.com mailing list for the glibc project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: Another timezone problem


Hi Andreas,

I think this patch solves the problems.  The -1168 is exactly the
offset between GMT and Amsterdam Mean Time, stored in the first rule
that's in the timezone file.

Mark


1999-03-30  Mark Kettenis  <kettenis@gnu.org>

	* time/tzfile.c (__tzfile_read): Set rule_stdoff and rule_dstoff
	according to the latest rules instead of the first rule.


--- /home/kettenis/CVS/libc/time/tzfile.c	Tue Mar 30 21:16:35 1999
+++ libc/time/tzfile.c	Tue Mar 30 21:21:11 1999
@@ -313,7 +313,7 @@
     {
       int stdoff_set = 0, dstoff_set = 0;
       rule_stdoff = rule_dstoff = 0;
-      for (i = 0; i < num_transitions; ++i)
+      for (i = num_transitions - 1; i >= 0; i--)
 	{
 	  if (!stdoff_set && !types[type_idxs[i]].isdst)
 	    {


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]