Subject: Re: [Boost-bugs] [Boost C++ Libraries] #4327: warning C4244: conversion from '__int64' to 'long', possible loss of data
From: Boost C++ Libraries (noreply_at_[hidden])
Date: 2011-03-10 17:47:48
#4327: warning C4244: conversion from '__int64' to 'long', possible loss of data
--------------------------------------+-------------------------------------
Reporter: viboes | Owner: anthonyw
Type: Bugs | Status: new
Milestone: Boost 1.44.0 | Component: thread
Version: Boost Development Trunk | Severity: Problem
Resolution: | Keywords:
--------------------------------------+-------------------------------------
Comment (by Pavel Machyniak <machyniak@â¦>):
While it will be fixed, here is workaround: convert to absolute time.
Example (boost 1.46):
{{{
void sleepMillisec( long milliseconds )
{
boost::this_thread::sleep(
boost::get_system_time() +
boost::posix_time::milliseconds( std::max<long>(milliseconds,0) )
);
}
}}}
-- Ticket URL: <https://svn.boost.org/trac/boost/ticket/4327#comment:11> 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:50:05 UTC