diff options
author | Jason Hood <jadoxa@yahoo.com.au> | 2019-02-14 18:42:51 +1000 |
---|---|---|
committer | Nico Williams <nico@cryptonector.com> | 2019-02-16 20:42:25 -0600 |
commit | 80b064f97b0429c4efa9abc7c045c26b3ab3e640 (patch) | |
tree | 1daae436732adec9eb57c54469c3d46d6f3c2eae | |
parent | 0fc8200ab42ea2b629fa0852987cfd4f6346b2dc (diff) |
Make UTC time on Windows
Windows has `_mkgmtime` for the UTC equivalent of `mktime`.
-rw-r--r-- | src/builtin.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/builtin.c b/src/builtin.c index 3cde61a3..eb2cd876 100644 --- a/src/builtin.c +++ b/src/builtin.c @@ -1238,6 +1238,8 @@ static time_t my_mktime(struct tm *tm) { if (t == (time_t)-1) return t; return t + tm->__tm_gmtoff; +#elif WIN32 + return _mkgmtime(tm); #else char *tz; |