]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
backport: re PR libstdc++/59680 (Compile error in thread.cc)
authorJonathan Wakely <jwakely@redhat.com>
Tue, 11 Mar 2014 21:06:21 +0000 (21:06 +0000)
committerJonathan Wakely <redi@gcc.gnu.org>
Tue, 11 Mar 2014 21:06:21 +0000 (21:06 +0000)
2014-03-11  Jonathan Wakely  <jwakely@redhat.com>

Backport from mainline.
2014-01-09  Jonathan Wakely  <jwakely@redhat.com>

PR libstdc++/59680
* src/c++11/thread.cc (__sleep_for): Fix call to ::sleep.

From-SVN: r208497

libstdc++-v3/ChangeLog
libstdc++-v3/src/c++11/thread.cc

index 0e95706eda6d4be459a884d21227c15354a54d2b..45b207f2ad9c76886b049be576cbac85fb20dfbb 100644 (file)
@@ -1,3 +1,11 @@
+2014-03-11  Jonathan Wakely  <jwakely@redhat.com>
+
+       Backport from mainline.
+       2014-01-09  Jonathan Wakely  <jwakely@redhat.com>
+
+       PR libstdc++/59680
+       * src/c++11/thread.cc (__sleep_for): Fix call to ::sleep.
+
 2014-03-11  Jonathan Wakely  <jwakely@redhat.com>
 
        Backport from mainline.
index 8d040a729a4a997f53930407566f7dd974406682..0351f19e042b0701ba3c2597ecec87144fd631d5 100644 (file)
@@ -183,7 +183,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
         ::usleep(__us);
       }
 # else
-    ::sleep(__s.count() + (__ns >= 1000000));
+    ::sleep(__s.count() + (__ns.count() >= 1000000));
 # endif
 #elif defined(_GLIBCXX_HAVE_WIN32_SLEEP)
     unsigned long ms = __ns.count() / 1000000;