$include_dir="/home/hyper-archives/boost/include"; include("$include_dir/msg-header.inc") ?>
Subject: [boost] [chrono, trunk] linux compile fix
From: Tim Blechmann (tim_at_[hidden])
Date: 2011-05-25 07:31:21
today's trunk does not compile correctly. this trivial patch fixes the issue:
thanks, tim
Index: boost/chrono/detail/inlined/posix/thread_clock.hpp
===================================================================
--- boost/chrono/detail/inlined/posix/thread_clock.hpp (revision 72154)
+++ boost/chrono/detail/inlined/posix/thread_clock.hpp (working copy)
@@ -21,6 +21,7 @@
thread_clock::time_point thread_clock::now( )
{
+ struct timespec ts;
#if defined CLOCK_THREAD_CPUTIME_ID
// get the timespec associated to the thread clock
if ( ::clock_gettime( CLOCK_THREAD_CPUTIME_ID, &ts ) )
@@ -31,7 +32,6 @@
clockid_t clock_id;
pthread_getcpuclockid(pth, &clock_id);
// get the timespec associated to the thread clock
- struct timespec ts;
if ( ::clock_gettime( clock_id, &ts ) )
#endif
{
@@ -49,6 +49,7 @@
}
thread_clock::time_point thread_clock::now( system::error_code & ec )
{
+ struct timespec ts;
#if defined CLOCK_THREAD_CPUTIME_ID
// get the timespec associated to the thread clock
if ( ::clock_gettime( CLOCK_THREAD_CPUTIME_ID, &ts ) )
@@ -59,7 +60,6 @@
clockid_t clock_id;
pthread_getcpuclockid(pth, &clock_id);
// get the timespec associated to the thread clock
- struct timespec ts;
if ( ::clock_gettime( clock_id, &ts ) )
#endif
{