summaryrefslogtreecommitdiff
path: root/src/time/localtime.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/time/localtime.c')
-rw-r--r--src/time/localtime.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/time/localtime.c b/src/time/localtime.c
index 72040d00..ddfecab5 100644
--- a/src/time/localtime.c
+++ b/src/time/localtime.c
@@ -8,6 +8,10 @@ struct tm * localtime(const time_t * timer)
static struct tm tm = {0};
ASSERT_NONNULL(timer);
+ #ifdef _POSIX_SOURCE
+ tzset();
+ #endif
+
tm = *gmtime(timer);
/* TODO: adjust for timezone */