about summary refs log tree commit diff
path: root/time/timegm.c
diff options
context:
space:
mode:
Diffstat (limited to 'time/timegm.c')
-rw-r--r--time/timegm.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/time/timegm.c b/time/timegm.c
index f63aac94ca..4dd87f46d2 100644
--- a/time/timegm.c
+++ b/time/timegm.c
@@ -22,6 +22,7 @@ time_t
 timegm (tmp)
      struct tm *const tmp;
 {
+  static time_t gmtime_offset;
   tmp->tm_isdst = 0;
-  return __mktime_internal (tmp, __gmtime_r);
+  return __mktime_internal (tmp, __gmtime_r, &gmtime_offset);
 }