[Python-checkins] cpython (3.3): fix zipimport ref leak

benjamin.peterson python-checkins at python.org
Thu Jan 9 16:37:06 CET 2014


http://hg.python.org/cpython/rev/d28242a636c7
changeset: 88365:d28242a636c7
branch: 3.3
parent: 88363:0cf1defd5ac4
user: Benjamin Peterson <benjamin at python.org>
date: Thu Jan 09 09:36:10 2014 -0600
summary:
 fix zipimport ref leak
files:
 Modules/zipimport.c | 4 +---
 1 files changed, 1 insertions(+), 3 deletions(-)
diff --git a/Modules/zipimport.c b/Modules/zipimport.c
--- a/Modules/zipimport.c
+++ b/Modules/zipimport.c
@@ -958,10 +958,8 @@
 }
 Py_XDECREF(self->files); /* free the old value. */
 self->files = files;
- } else {
- /* No problem, discard the new stat data. */
- Py_DECREF(stat_now);
 }
+ Py_DECREF(stat_now);
 } /* stat succeeded */
 
 return fp;
-- 
Repository URL: http://hg.python.org/cpython


More information about the Python-checkins mailing list

AltStyle によって変換されたページ (->オリジナル) /