about summary refs log tree commit diff
path: root/time/tzfile.c
diff options
context:
space:
mode:
Diffstat (limited to 'time/tzfile.c')
-rw-r--r--time/tzfile.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/time/tzfile.c b/time/tzfile.c
index 9fab857ecc..1d51a695ff 100644
--- a/time/tzfile.c
+++ b/time/tzfile.c
@@ -415,13 +415,13 @@ find_transition (time_t timer)
 int
 __tzfile_compute (time_t timer, int use_localtime,
 		  long int *leap_correct, int *leap_hit,
-		  int *isdst, long int *offset)
+		  struct tm *tp)
 {
-  struct ttinfo *info = find_transition (timer);
   register size_t i;
 
   if (use_localtime)
     {
+      struct ttinfo *info = find_transition (timer);
       __daylight = rule_stdoff != rule_dstoff;
       __timezone = -rule_stdoff;
       __tzname[1] = NULL;
@@ -432,11 +432,11 @@ __tzfile_compute (time_t timer, int use_localtime,
       if (__tzname[1] == NULL)
 	/* There is no daylight saving time.  */
 	__tzname[1] = __tzname[0];
+      tp->tm_isdst = info->isdst;
+      tp->tm_zone = &zone_names[info->idx];
+      tp->tm_gmtoff = info->offset;
     }
 
-  *isdst = info->isdst;
-  *offset = info->offset;
-
   *leap_correct = 0L;
   *leap_hit = 0;