In MSVCRT_localtime() return tm_isdst = 0 when there are no daylight
time changes in the local time zone.
This commit is contained in:
parent
c639af64be
commit
2fc0f991d8
|
@ -124,11 +124,10 @@ struct MSVCRT_tm* MSVCRT_localtime(const MSVCRT_time_t* secs)
|
||||||
|
|
||||||
tzid = GetTimeZoneInformation(&tzinfo);
|
tzid = GetTimeZoneInformation(&tzinfo);
|
||||||
|
|
||||||
if (tzid == TIME_ZONE_ID_UNKNOWN || tzid == TIME_ZONE_ID_INVALID) {
|
if (tzid == TIME_ZONE_ID_INVALID)
|
||||||
tm.tm_isdst = -1;
|
tm.tm_isdst = -1;
|
||||||
} else {
|
else
|
||||||
tm.tm_isdst = (tzid == TIME_ZONE_ID_DAYLIGHT?1:0);
|
tm.tm_isdst = (tzid == TIME_ZONE_ID_DAYLIGHT?1:0);
|
||||||
}
|
|
||||||
|
|
||||||
return &tm;
|
return &tm;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue