aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJonathan Wakely <jwakely@redhat.com>2014-01-09 23:39:31 +0000
committerJonathan Wakely <redi@gcc.gnu.org>2014-01-09 23:39:31 +0000
commit4bc0ec326170cb9307c3fe226627e5b381078266 (patch)
treeee5aecdc46933c431f165e0af8aafcabb6141a48
parentcd4447e235c721a54746936f4ce9265c754af7f1 (diff)
downloadgcc-4bc0ec326170cb9307c3fe226627e5b381078266.zip
gcc-4bc0ec326170cb9307c3fe226627e5b381078266.tar.gz
gcc-4bc0ec326170cb9307c3fe226627e5b381078266.tar.bz2
re PR libstdc++/59680 (Compile error in thread.cc)
PR libstdc++/59680 * src/c++11/thread.cc (__sleep_for): Fix call to ::sleep. From-SVN: r206504
-rw-r--r--libstdc++-v3/ChangeLog3
-rw-r--r--libstdc++-v3/src/c++11/thread.cc2
2 files changed, 4 insertions, 1 deletions
diff --git a/libstdc++-v3/ChangeLog b/libstdc++-v3/ChangeLog
index d73a0b3..19269f5 100644
--- a/libstdc++-v3/ChangeLog
+++ b/libstdc++-v3/ChangeLog
@@ -4,6 +4,9 @@
* include/bits/stl_vector.h (vector<>::_M_move_assign): Restore
support for non-Movable types.
+ PR libstdc++/59680
+ * src/c++11/thread.cc (__sleep_for): Fix call to ::sleep.
+
2014-01-08 François Dumont <fdumont@gcc.gnu.org>
* include/bits/stl_vector.h (std::vector<>::_M_move_assign): Pass
diff --git a/libstdc++-v3/src/c++11/thread.cc b/libstdc++-v3/src/c++11/thread.cc
index d7c3fb1..49aacb5 100644
--- a/libstdc++-v3/src/c++11/thread.cc
+++ b/libstdc++-v3/src/c++11/thread.cc
@@ -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;