From 4633ea3bc83182c75a659d73d63c727fd819ba68 Mon Sep 17 00:00:00 2001 From: Thomas Schmitt Date: Sat, 10 Oct 2015 21:31:13 +0200 Subject: [PATCH] Explicitely set tm_isdst to 0 before calling timegm. Coverity CID 12591. --- libisofs/util.c | 1 + 1 file changed, 1 insertion(+) diff --git a/libisofs/util.c b/libisofs/util.c index 159ca82..786e19b 100644 --- a/libisofs/util.c +++ b/libisofs/util.c @@ -1804,6 +1804,7 @@ time_t iso_datetime_read_7(const uint8_t *buf) tm.tm_hour = buf[3]; tm.tm_min = buf[4]; tm.tm_sec = buf[5]; + tm.tm_isdst = 0; return timegm(&tm) - ((int8_t)buf[6]) * 60 * 15; }