Windows: fix timezone calculation

Comparing to daylight-saving time change was performed incorrectly, so
that days in the same month as a change and the hour within the day before
the switch hour were all treated as pre-switch (instead of counting
only days up to the switch as pre-switch).

Thanks to Jon Zeppieri for the repair and George Neuner for
the report.
This commit is contained in:
Matthew Flatt 2016-11-09 05:57:05 -08:00
parent e7a6573a20
commit db26a24f2f

View File

@ -9875,6 +9875,8 @@ static int is_day_before(SYSTEMTIME *a, SYSTEMTIME *b)
if (a->wDay < doc)
return 1;
if (a->wDay > doc)
return 0;
dtxCOMP(wHour);
dtxCOMP(wMinute);