mirror of
https://github.com/python/cpython.git
synced 2025-11-01 18:51:43 +00:00
parent
7317c1ef7a
commit
5f95257ef9
2 changed files with 4 additions and 0 deletions
|
|
@ -22,6 +22,8 @@ Core and Builtins
|
|||
Library
|
||||
-------
|
||||
|
||||
- Issue #4373: Corrected a potential reference leak in the pickle module.
|
||||
|
||||
- Issue #4382: dbm.dumb did not specify the expected file encoding for opened
|
||||
files.
|
||||
|
||||
|
|
|
|||
|
|
@ -486,11 +486,13 @@ unpickler_read(UnpicklerObject *self, char **s, Py_ssize_t n)
|
|||
PyErr_SetString(PyExc_ValueError,
|
||||
"read() from the underlying stream did not"
|
||||
"return bytes");
|
||||
Py_DECREF(data);
|
||||
return -1;
|
||||
}
|
||||
|
||||
if (PyBytes_GET_SIZE(data) != n) {
|
||||
PyErr_SetNone(PyExc_EOFError);
|
||||
Py_DECREF(data);
|
||||
return -1;
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue