Message155025
PyObject_GenericSetAttr() doesn't keep a reference to the descriptor: Python does crash if the descriptor is destroyed while the attribute is set. Attached patch keeps a reference to the desriptor to avoid the crash.
A smililar was done in PyObject_GenericGetAttr() 8 years with the changelog "fix obscure crash in descriptor handling", see the changeset 941d49a65f06.
The patch fixes Lib/test/crashers/borrowed_ref_2.py and so removes it. |
|
Date |
User |
Action |
Args |
2012-03-06 17:19:06 | vstinner | set | recipients:
+ vstinner |
2012-03-06 17:19:05 | vstinner | set | messageid: <1331054345.96.0.65871889242.issue14211@psf.upfronthosting.co.za> |
2012-03-06 17:19:05 | vstinner | link | issue14211 messages |
2012-03-06 17:19:05 | vstinner | create | |
|