mirror of
https://github.com/python/cpython
synced 2024-09-05 16:38:56 +00:00
bug 1234979 addition
This commit is contained in:
parent
af410b510d
commit
9a3240e8e6
|
@ -140,13 +140,13 @@ int PyThread_acquire_lock(PyThread_type_lock aLock, int waitflag)
|
|||
dprintf(("%ld: PyThread_acquire_lock(%p, %d) called\n", PyThread_get_thread_ident(),aLock, waitflag));
|
||||
|
||||
#ifndef DEBUG
|
||||
waitResult = WaitForSingleObject(aLock, (waitflag == 1 ? INFINITE : 0));
|
||||
waitResult = WaitForSingleObject(aLock, (waitflag ? INFINITE : 0));
|
||||
#else
|
||||
/* To aid in debugging, we regularly wake up. This allows us to
|
||||
break into the debugger */
|
||||
while (TRUE) {
|
||||
waitResult = WaitForSingleObject(aLock, waitflag ? 3000 : 0);
|
||||
if (waitflag==0 || (waitflag==1 && waitResult == WAIT_OBJECT_0))
|
||||
if (waitflag==0 || (waitflag && waitResult == WAIT_OBJECT_0))
|
||||
break;
|
||||
}
|
||||
#endif
|
||||
|
|
Loading…
Reference in a new issue