summaryrefslogtreecommitdiffstats
path: root/src/corelib/thread
diff options
context:
space:
mode:
authorThiago Macieira <thiago@kde.org>2011-07-21 15:10:30 (GMT)
committerOlivier Goffart <olivier.goffart@nokia.com>2011-07-22 08:30:36 (GMT)
commitf6735134a3637ae09442ad592f74a551830577fc (patch)
treeb84dda5f2ff74cbf84fc8225d6a3346d1c5d0956 /src/corelib/thread
parent433872d7e26a6a99297e231ac3bc0f603c9cefe8 (diff)
downloadQt-f6735134a3637ae09442ad592f74a551830577fc.zip
Qt-f6735134a3637ae09442ad592f74a551830577fc.tar.gz
Qt-f6735134a3637ae09442ad592f74a551830577fc.tar.bz2
Fix the timeout calculation again.
The commit 412ef92162f8874a1585221125c31ef5f8ccc9cb introduced a fix, but the fix was incomplete. Fix it for good. Change-Id: I3e7fbdb294f8e960fbbf2e830790750240ed813a Merge-request: 30 Reviewed-by: Olivier Goffart <olivier.goffart@nokia.com> Reviewed-on: http://codereview.qt.nokia.com/1991 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> (cherry picked from commit 038d7c6c3b9815068e1f5b6df12625181f0313e1)
Diffstat (limited to 'src/corelib/thread')
-rw-r--r--src/corelib/thread/qmutex_unix.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/corelib/thread/qmutex_unix.cpp b/src/corelib/thread/qmutex_unix.cpp
index e692e19..2a9d23c 100644
--- a/src/corelib/thread/qmutex_unix.cpp
+++ b/src/corelib/thread/qmutex_unix.cpp
@@ -161,8 +161,8 @@ bool QMutexPrivate::wait(int timeout)
return false;
}
- ts.tv_sec = timeout / Q_INT64_C(1000) / 1000 / 1000;
- ts.tv_nsec = timeout % (Q_INT64_C(1000) * 1000 * 1000);
+ ts.tv_sec = xtimeout / Q_INT64_C(1000) / 1000 / 1000;
+ ts.tv_nsec = xtimeout % (Q_INT64_C(1000) * 1000 * 1000);
}
}
return true;