]> git.ipfire.org Git - thirdparty/glibc.git/commitdiff
Interpret no DST information in user provided time zone specification
authorUlrich Drepper <drepper@redhat.com>
Sat, 16 Aug 1997 19:51:08 +0000 (19:51 +0000)
committerUlrich Drepper <drepper@redhat.com>
Sat, 16 Aug 1997 19:51:08 +0000 (19:51 +0000)
as it is meant: no DST.

time/tzset.c

index ca05fa81c57440c4cde98dde5f734a6f20bfd547..42b006e0c17be8c51cb0c857f967038cb37e155b 100644 (file)
@@ -304,6 +304,18 @@ __tzset_internal (always)
          if (l < 2 && *tz == ':')
            ++tz;
        }
+      if (*tz == '\0' || (tz[0] == ',' && tz[1] == '\0'))
+       {
+         /* There is no rule.  See if there is a default rule file.  */
+         __tzfile_default (tz_rules[0].name, tz_rules[1].name,
+                           tz_rules[0].offset, tz_rules[1].offset);
+         if (__use_tzfile)
+           {
+             free (old_tz);
+             old_tz = NULL;
+             return;
+           }
+       }
     }
   else
     /* There is no DST.  */
@@ -312,19 +324,6 @@ __tzset_internal (always)
  done_names:
   free (tzbuf);
 
-  if (*tz == '\0' || (tz[0] == ',' && tz[1] == '\0'))
-    {
-      /* There is no rule.  See if there is a default rule file.  */
-      __tzfile_default (tz_rules[0].name, tz_rules[1].name,
-                       tz_rules[0].offset, tz_rules[1].offset);
-      if (__use_tzfile)
-       {
-         free (old_tz);
-         old_tz = NULL;
-         return;
-       }
-    }
-
   /* Figure out the standard <-> DST rules.  */
   for (whichrule = 0; whichrule < 2; ++whichrule)
     {