This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author serhiy.storchaka
Recipients Arfrever, belopolsky, larry, martin.panter, pitrou, serhiy.storchaka, skrah
Date 2015-02-01.22:13:01
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <>
from_buffer() uses a memory buffer of other object. It keeps a reference to the object to prevent deallocation of memory when there will be no more external references. But this doesn't prevent from reallocating of memory of living object (e.g. for resizing of bytearray). So we need to grab the buffer (with PyObject_GetBuffer) in from_buffer() and free it (with PyBuffer_Release) when it is no longer needed. menoryview can do this but needs a hack, because a memoryview created by PyMemoryView_FromBuffer() doesn't release the buffer. May be there is more official way?
Date User Action Args
2015-02-01 22:13:01serhiy.storchakasetrecipients: + serhiy.storchaka, belopolsky, pitrou, larry, Arfrever, skrah, martin.panter
2015-02-01 22:13:01serhiy.storchakasetmessageid: <>
2015-02-01 22:13:01serhiy.storchakalinkissue22896 messages
2015-02-01 22:13:01serhiy.storchakacreate