[Python-checkins] cpython (3.4): fix refleak in error condition
benjamin.peterson
python-checkins at python.org
Thu Jan 21 01:08:02 EST 2016
https://hg.python.org/cpython/rev/eb19459ce46a
changeset: 100012:eb19459ce46a
branch: 3.4
parent: 100008:562179b7912f
user: Benjamin Peterson <benjamin at python.org>
date: Wed Jan 20 22:06:43 2016 -0800
summary:
fix refleak in error condition
files:
Modules/zipimport.c | 1 +
1 files changed, 1 insertions(+), 0 deletions(-)
diff --git a/Modules/zipimport.c b/Modules/zipimport.c
--- a/Modules/zipimport.c
+++ b/Modules/zipimport.c
@@ -1127,6 +1127,7 @@
bytes_read = fread(buf, 1, data_size, fp);
} else {
fclose(fp);
+ Py_DECREF(raw_data);
PyErr_Format(ZipImportError, "can't read Zip file: %R", archive);
return NULL;
}
--
Repository URL: https://hg.python.org/cpython
More information about the Python-checkins
mailing list