This is the mail archive of the libc-alpha@sources.redhat.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]
Other format: [Raw text]

Timezone POSIX compliance bug.


SUSv3 says this about the TZ offset:

The hour shall be between zero and 24, and the minutes (and seconds)-if
present-between zero and 59.  

glibc currently clips this range at 23 hours.

2003-12-20  Jeff Bailey  <jbailey@gnu.org>

	* time/tzset.c: Allow TZ offsets up to 24 hours.

Index: tzset.c
===================================================================
RCS file: /cvs/glibc/libc/time/tzset.c,v
retrieving revision 1.74
diff -u -p -r1.74 tzset.c
--- tzset.c     1 Feb 2003 20:50:28 -0000       1.74
+++ tzset.c     21 Dec 2003 04:36:49 -0000
@@ -241,7 +241,7 @@ tzset_internal (always)
       break;
     }
   tz_rules[0].offset *= (min (ss, 59) + (min (mm, 59) * 60) +
-                        (min (hh, 23) * 60 * 60));
+                        (min (hh, 24) * 60 * 60));
  
   for (l = 0; l < 3; ++l)
     {


Attachment: signature.asc
Description: This is a digitally signed message part


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