diff options
author | Antoine Pitrou <solipsis@pitrou.net> | 2010-05-03 16:25:33 (GMT) |
---|---|---|
committer | Antoine Pitrou <solipsis@pitrou.net> | 2010-05-03 16:25:33 (GMT) |
commit | f7fd8e4c9492defbb32cc142faaf3abeabd00cf8 (patch) | |
tree | 8854e7a740532f8b6b746e9e5c4118b95ad758f9 /Modules/_io/bytesio.c | |
parent | c3ce9e357dac697561a8c97e977e49db321571e3 (diff) | |
download | cpython-f7fd8e4c9492defbb32cc142faaf3abeabd00cf8.zip cpython-f7fd8e4c9492defbb32cc142faaf3abeabd00cf8.tar.gz cpython-f7fd8e4c9492defbb32cc142faaf3abeabd00cf8.tar.bz2 |
Issue #7865: The close() method of :mod:`io` objects should not swallow
exceptions raised by the implicit flush(). Also ensure that calling
close() several times is supported. Patch by Pascal Chambon.
Diffstat (limited to 'Modules/_io/bytesio.c')
-rw-r--r-- | Modules/_io/bytesio.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/Modules/_io/bytesio.c b/Modules/_io/bytesio.c index 25ff247..a294332 100644 --- a/Modules/_io/bytesio.c +++ b/Modules/_io/bytesio.c @@ -169,6 +169,7 @@ PyDoc_STRVAR(flush_doc, static PyObject * bytesio_flush(bytesio *self) { + CHECK_CLOSED(self); Py_RETURN_NONE; } |