summaryrefslogtreecommitdiffstats
path: root/Modules/_pickle.c
diff options
context:
space:
mode:
authorAlexander Belopolsky <alexander.belopolsky@gmail.com>2011-02-24 19:40:09 (GMT)
committerAlexander Belopolsky <alexander.belopolsky@gmail.com>2011-02-24 19:40:09 (GMT)
commit1ce92dc20d698ce46c3459da7801c76bb8518550 (patch)
tree26455f0ab85013e2095744fa179ae197500bd1aa /Modules/_pickle.c
parent6c3787cb70d8efa5f70939a5db300f56a724d698 (diff)
downloadcpython-1ce92dc20d698ce46c3459da7801c76bb8518550.zip
cpython-1ce92dc20d698ce46c3459da7801c76bb8518550.tar.gz
cpython-1ce92dc20d698ce46c3459da7801c76bb8518550.tar.bz2
Issue #11286: Fixed unpickling of empty 2.x strings.
Diffstat (limited to 'Modules/_pickle.c')
-rw-r--r--Modules/_pickle.c5
1 files changed, 0 insertions, 5 deletions
diff --git a/Modules/_pickle.c b/Modules/_pickle.c
index b01a8b2..fb6281e 100644
--- a/Modules/_pickle.c
+++ b/Modules/_pickle.c
@@ -977,11 +977,6 @@ _Unpickler_Read(UnpicklerObject *self, char **s, Py_ssize_t n)
{
Py_ssize_t num_read;
- if (n == 0) {
- *s = NULL;
- return 0;
- }
-
if (self->next_read_idx + n <= self->input_len) {
*s = self->input_buffer + self->next_read_idx;
self->next_read_idx += n;