diff options
author | Matthew Newhook <matthew@zeroc.com> | 2005-07-11 18:10:40 +0000 |
---|---|---|
committer | Matthew Newhook <matthew@zeroc.com> | 2005-07-11 18:10:40 +0000 |
commit | 5611579110ed0c87336894a0ad1ab6fdad149644 (patch) | |
tree | a75c3d6e99a2e0b92151ce3a61c3a5b19f221a98 /cpp/src/IceUtil/Cond.cpp | |
parent | Added Ice.Warn.Endpoints (diff) | |
download | ice-5611579110ed0c87336894a0ad1ab6fdad149644.tar.bz2 ice-5611579110ed0c87336894a0ad1ab6fdad149644.tar.xz ice-5611579110ed0c87336894a0ad1ab6fdad149644.zip |
http://bugzilla.zeroc.com/bugzilla/show_bug.cgi?id=397
Diffstat (limited to 'cpp/src/IceUtil/Cond.cpp')
-rw-r--r-- | cpp/src/IceUtil/Cond.cpp | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/cpp/src/IceUtil/Cond.cpp b/cpp/src/IceUtil/Cond.cpp index 3654fa9b8c3..3e042181bc5 100644 --- a/cpp/src/IceUtil/Cond.cpp +++ b/cpp/src/IceUtil/Cond.cpp @@ -42,10 +42,7 @@ IceUtil::Semaphore::wait() const bool IceUtil::Semaphore::timedWait(const Time& timeout) const { - timeval tv = timeout; - long msec = (tv.tv_sec * 1000) + (tv.tv_usec / 1000); - - int rc = WaitForSingleObject(_sem, msec); + int rc = WaitForSingleObject(_sem, static_cast<long>(timeout.toMilliSeconds())); if(rc != WAIT_TIMEOUT && rc != WAIT_OBJECT_0) { throw ThreadSyscallException(__FILE__, __LINE__, GetLastError()); |