Boost logo

Boost Users :

Subject: [Boost-users] handling of daylight saving time...
From: Archie14 (admin_at_[hidden])
Date: 2010-04-30 11:22:05


My software records time events on the computer and it does it using whatever
timezone and daylight saving time settings are on this computer. I realized
too late that, while storing timestamps, I am not accounting for this daylight
adjustment process. So, if hypothetically speaking, the daylight adjustment
happens today at 9:00 am and I am writing my timestamps every second I will
have something like that:
…
8.58
8.59
9.00
10.01 (without timesaving should be 9.01)
10.02 (without timesaving should be 9.02)
…
 When I am reading my timestamps back I am constructing timezone and using it
for timestamps manipulation
 std::string gmt = (boost::format("TMZ%1%
TMS1:00:00,M3.2.0/02:00:00,M11.1.0/02:00:00") % gmtoffset).str();
, but this one-hour gap persists, as I now think it should.

The question is: is it possible to do manipulation with datetime library to
remove this gap without hard-coding one hour removal after specific date/time
of daylight saving time?


Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net