[Development] How does mktime() handle DST transitions ?

André Somers andre at familiesomers.nl
Thu Nov 5 13:10:33 CET 2015


Op 5-11-2015 om 00:06 schreef Kevin Kofler:
> Welbourne Edward wrote:
>> I'm looking into QTBUG-49008 and need to work out how diverse
>> implementations of mktime handle DST transitions: at one end of the year
>> there's a gap (where 1:59 is followed by 3:00), at the other end there's
>> a duplicated hour (where 2:59 is followed by a reprise of 2:00 in
>> Europe, or 1:59 by 1:00 in the USA, IIUC).  While we still need to work
>> out what behaviour *we* want to give, implementing it is going to depend
>> on knowing what the platform mktime gives us to work with.
> The EU actually defines the switchover time in UTC, so which hour is
> duplicated depends on the actual time zone. It's the 3:mm hour in CET/CEST.
>
>          
Nonsense*. I live in the CET (Netherlands), I am 100% sure that the hour 
duplicated is the 2:mm range, not the 3:mm range. At 03:00, the time is 
reset to 02:00 entering winter time again. That happened last October 
25. Going to summer time, the hour skipped is the 2:mm range also.

André

*) At least in so far the actual clock time in the country is concerned. 
Perhaps for other purposes the EU defines a single switchover moment for 
the whole of the EU? That is pure speculation though.





More information about the Development mailing list