Message259252
Previous attempt to fix reference leaks was in issue984722.
Proposed patch uses different approach. It correctly fixes reference leaks after error in processing dict items (like "{()s(())N"), fixes leaksafter memory errors on creating tuple, list or dict, fixes issue20024 for lists and dicts, fixes use-after-free issue described in msg259242.
But the patch has a disadvantage in comparison with current code. If user converter ("O&") accepts Python objects and steal its reference (as "N"), this reference will be leaked. This is a price for avoiding potential use-after-free issues. Current stdlib code doesn't use converters that steal Python object reference. May be we should document this limitation. |
|
Date |
User |
Action |
Args |
2016-01-30 11:23:40 | serhiy.storchaka | set | recipients:
+ serhiy.storchaka, mwh, rhettinger, shredwheat, martin.panter, josh.r, squidevil |
2016-01-30 11:23:40 | serhiy.storchaka | set | messageid: <1454153020.0.0.629955803415.issue26168@psf.upfronthosting.co.za> |
2016-01-30 11:23:39 | serhiy.storchaka | link | issue26168 messages |
2016-01-30 11:23:37 | serhiy.storchaka | create | |
|