[Boost-bugs] [Boost C++ Libraries] #1268: xtime_cmp changes to deal with overflow were reverted

Subject: [Boost-bugs] [Boost C++ Libraries] #1268: xtime_cmp changes to deal with overflow were reverted
From: Boost C++ Libraries (noreply_at_[hidden])
Date: 2007-09-14 19:41:10


#1268: xtime_cmp changes to deal with overflow were reverted
------------------------------+---------------------------------------------
 Reporter: oseiler_at_[hidden] | Owner: anthonyw
     Type: Bugs | Status: new
Milestone: To Be Determined | Component: thread
  Version: Boost 1.34.1 | Severity: Problem
 Keywords: |
------------------------------+---------------------------------------------
 I'm running into this situation when specifying a very long timeout that
 winds up using boost::condition::timed_wait with an xtime value set up
 like so:

 boost::xtime xt;
 boost::xtime_get( &xt, boost::TIME_UTC );
 xt.sec += std::numeric_limits<uint32_t>::max(); // ignore potential
 overflow, as sec is 64-bit
 condition.timed_wait( lock, xt ); // <- this returns immediately

 Traced this down to an overflow in xtime_cmp (boost/thread/xtime.hpp) that
 was fixed in version 1.14 of the file and reverted in version 1.15 of the
 file (replaced with the pre-1.14 version).

 This is present in 1.33.1 (version being used on project) and in 1.34.1.

--
Ticket URL: <http://svn.boost.org/trac/boost/ticket/1268>
Boost C++ Libraries <http://www.boost.org/>
Boost provides free peer-reviewed portable C++ source libraries.


This archive was generated by hypermail 2.1.7 : 2017-02-16 18:49:56 UTC