Issue #23099: Closing io.BytesIO with exported buffer is rejected now to

prevent corrupting exported buffer.
This commit is contained in:
Serhiy Storchaka 2015-02-03 09:30:51 +02:00
commit 32ca3dcb97
5 changed files with 23 additions and 7 deletions

View file

@ -779,6 +779,7 @@ PyDoc_STRVAR(close_doc,
static PyObject *
bytesio_close(bytesio *self)
{
CHECK_EXPORTS(self);
reset(self);
Py_RETURN_NONE;
}