qthread_win.cpp: Fix warnings when waiting for adopted threads.
Task-number: QTBUG-35591 Change-Id: I63169bd8a9758a7dad33d4231d3d6c9d71c7e252 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>bb10
parent
be29c4053e
commit
d1f8a56416
|
|
@ -208,7 +208,11 @@ DWORD WINAPI qt_adopted_thread_watcher_function(LPVOID)
|
|||
qt_adopted_thread_watcher_mutex.unlock();
|
||||
|
||||
DWORD ret = WAIT_TIMEOUT;
|
||||
int loops = (handlesCopy.count() / MAXIMUM_WAIT_OBJECTS) + 1, offset, count;
|
||||
int count;
|
||||
int offset;
|
||||
int loops = handlesCopy.size() / MAXIMUM_WAIT_OBJECTS;
|
||||
if (handlesCopy.size() % MAXIMUM_WAIT_OBJECTS)
|
||||
++loops;
|
||||
if (loops == 1) {
|
||||
// no need to loop, no timeout
|
||||
offset = 0;
|
||||
|
|
|
|||
Loading…
Reference in New Issue