Boost logo

Boost :

From: Harald Haspl (harald.haspl_at_[hidden])
Date: 2005-06-28 11:53:44


Hello,

we just found an error inside the date-time library.

I use "boost::posix_time::microsec_clock::local_time()" to get the actual
time.
When the microseconds overflow and a new second starts, the seconds don't get
incremented atomically together with the microseconds.

Is this a known bug?

My System:
        boost version 1.31.0
        Linux 2.6.3, SMP (Red Hat Enterprise)
        2x Intel Xeon HT

Some values of consecutive calls:

call: 2005-Jun-28 15:00:24.978706
call: 2005-Jun-28 15:00:24.989132
FAILURE: 2005-Jun-28 15:00:24.000105
FAILURE: 2005-Jun-28 15:00:24.000210
FAILURE: 2005-Jun-28 15:00:24.000283
FAILURE: 2005-Jun-28 15:00:24.000353
FAILURE: 2005-Jun-28 15:00:24.000424
call: 2005-Jun-28 15:00:25.000503
call: 2005-Jun-28 15:00:25.010122
call: 2005-Jun-28 15:00:25.020088
call: 2005-Jun-28 15:00:25.030194

Regards,
Harald

-- 
Harald Haspl
apus | Software GmbH
Bahnhofstrasse 1, A-8074 Graz-Raaba                                  
T | +43 316 401629 0   F | +43 316 401629 9
http://www.apus.co.at  harald.haspl_at_[hidden]

Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk