Message218004
In thread_nt.h:EnterNonRecursiveMutex the millisecond version (here: 2148000) of the seconds you passed in are converted to microseconds (so: 2148000000).
This is then passed to condvar.h:PyCOND_TIMEDWAIT which expects a long, whose 32-bit limit is 2147483647. So it wraps around and becomes -2146967296.
That value is then divided by 1000 once again to become milliseconds (-2146967) and passed to condvar.h:_PyCOND_WAIT_MS which expects a DWORD, which is a synonym for an unsigned long. Thus the signed value becomes an unsigned 4292820329. Which then passed in as the millisecond timeout to WaitForSingleObjectEx.
So that's what's happening; but I'm really not sure at what stage a change should be made. It looks to me as if PyCOND_TIMEDWAIT should be accepting something more than a long, but I'm really not competent to assess the impact of such a change. |
|
Date |
User |
Action |
Args |
2014-05-06 19:04:20 | tim.golden | set | recipients:
+ tim.golden, pitrou, r.david.murray, brian.curtin, alex.gronholm, raruler |
2014-05-06 19:04:20 | tim.golden | set | messageid: <1399403060.42.0.00168177223749.issue20737@psf.upfronthosting.co.za> |
2014-05-06 19:04:20 | tim.golden | link | issue20737 messages |
2014-05-06 19:04:19 | tim.golden | create | |
|