Message316107
Correct me if I'm wrong, the change released in Python 2.7.15 doesn't actually fix this race condition.
The race is:
* T1: gc_was_enabled = gc.isenabled() # True
* T1: gc.disable()
* T2: gc_was_enabled = gc.isenabled() # False
* T1: gc.enable()
* T2: gc.disable()
To fix the race condition _disabling_gc_lock must also be held for gc.enable() in both call locations so it cannot happen between gc.isenabled() and gc.disable().
TBH, I'm not really expecting this to be fixed, this is more a note for any future travelers who come across this issue. |
|
Date |
User |
Action |
Args |
2018-05-03 03:59:16 | gwalker | set | recipients:
+ gwalker, gregory.p.smith, gps, r.david.murray, ppperry, aonishuk |
2018-05-03 03:59:16 | gwalker | set | messageid: <1525319956.03.0.682650639539.issue27448@psf.upfronthosting.co.za> |
2018-05-03 03:59:15 | gwalker | link | issue27448 messages |
2018-05-03 03:59:15 | gwalker | create | |
|