diff options
author | Tavian Barnes <tavianator@tavianator.com> | 2020-02-12 12:29:09 -0500 |
---|---|---|
committer | Tavian Barnes <tavianator@tavianator.com> | 2020-02-12 12:29:09 -0500 |
commit | 3bfdb184465da7684265b7b21a2c7f0ba5904998 (patch) | |
tree | 696aa1437c0cd97199ad4fa4a246e2e218ffc517 /parse.c | |
parent | 2bdd2d12801eada77945d4f6644248cf7952cc64 (diff) | |
download | bfs-3bfdb184465da7684265b7b21a2c7f0ba5904998.tar.xz |
parse: Set tm_isdst to -1
This is required by POSIX to ensure the mktime() determines itself
whether DST is in effect.
Diffstat (limited to 'parse.c')
-rw-r--r-- | parse.c | 4 |
1 files changed, 3 insertions, 1 deletions
@@ -1658,7 +1658,9 @@ static int parse_reftime_part(const struct parser_state *state, const char **str /** Parse an explicit reference time. */ static int parse_reftime(const struct parser_state *state, struct expr *expr) { const char *str = expr->sdata; - struct tm tm = {0}; + struct tm tm = { + .tm_isdst = -1, + }; int tz_hour = 0; int tz_min = 0; |