From 038d7c6c3b9815068e1f5b6df12625181f0313e1 Mon Sep 17 00:00:00 2001 From: Thiago Macieira Date: Thu, 21 Jul 2011 17:10:30 +0200 Subject: 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 Reviewed-on: http://codereview.qt.nokia.com/1991 Reviewed-by: Qt Sanity Bot --- src/corelib/thread/qmutex_unix.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src') diff --git a/src/corelib/thread/qmutex_unix.cpp b/src/corelib/thread/qmutex_unix.cpp index e692e19525..2a9d23c361 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; -- cgit v1.2.3