summaryrefslogtreecommitdiff
path: root/lib/timegm.c
diff options
context:
space:
mode:
authorDongHun Kwak <dh0128.kwak@samsung.com>2021-03-05 10:08:18 +0900
committerDongHun Kwak <dh0128.kwak@samsung.com>2021-03-05 10:08:18 +0900
commitb15fb2d17b19575dbd7314fc96d64cc64f9d5795 (patch)
treef635a67927c7be9409dc03ba6c5d746ace19a776 /lib/timegm.c
parent6403e0986cb5d0b8b4cbea66f8f3ff7a68cb4c20 (diff)
downloadwget-b15fb2d17b19575dbd7314fc96d64cc64f9d5795.tar.gz
wget-b15fb2d17b19575dbd7314fc96d64cc64f9d5795.tar.bz2
wget-b15fb2d17b19575dbd7314fc96d64cc64f9d5795.zip
Imported Upstream version 1.19upstream/1.19
Diffstat (limited to 'lib/timegm.c')
-rw-r--r--lib/timegm.c8
1 files changed, 5 insertions, 3 deletions
diff --git a/lib/timegm.c b/lib/timegm.c
index 11c485f..957a3b8 100644
--- a/lib/timegm.c
+++ b/lib/timegm.c
@@ -1,6 +1,6 @@
/* Convert UTC calendar time to simple time. Like mktime but assumes UTC.
- Copyright (C) 1994, 1997, 2003-2004, 2006-2007, 2009-2015 Free Software
+ Copyright (C) 1994, 1997, 2003-2004, 2006-2007, 2009-2017 Free Software
Foundation, Inc. This file is part of the GNU C Library.
This program is free software; you can redistribute it and/or modify
@@ -22,7 +22,9 @@
#include <time.h>
-#ifndef _LIBC
+#ifdef _LIBC
+typedef time_t mktime_offset_t;
+#else
# undef __gmtime_r
# define __gmtime_r gmtime_r
# define __mktime_internal mktime_internal
@@ -32,7 +34,7 @@
time_t
timegm (struct tm *tmp)
{
- static time_t gmtime_offset;
+ static mktime_offset_t gmtime_offset;
tmp->tm_isdst = 0;
return __mktime_internal (tmp, __gmtime_r, &gmtime_offset);
}