]> granicus.if.org Git - python/commit
Issue 3110: Crash with weakref subclass,
authorAmaury Forgeot d'Arc <amauryfa@gmail.com>
Mon, 16 Jun 2008 19:22:42 +0000 (19:22 +0000)
committerAmaury Forgeot d'Arc <amauryfa@gmail.com>
Mon, 16 Jun 2008 19:22:42 +0000 (19:22 +0000)
commit3255e134fea656b8a142720fe7005204015c5781
treeeefe76c55b3f49c99cf244ae946feecc611e20f7
parent75ee9eb9c60cc85925d2bfe9f92f2b2da81ddefd
Issue 3110: Crash with weakref subclass,
seen after a "import multiprocessing.reduction"

An instance of a weakref subclass can have attributes.
If such a weakref holds the only strong reference to the object,
deleting the weakref will delete the object. In this case,
the callback must not be called, because the ref object is being deleted!

Backport of r34309
Lib/test/test_weakref.py
Misc/NEWS
Objects/weakrefobject.c