[Python-checkins] cpython: zipimport: initialize fullpath to NULL
victor.stinner
python-checkins at python.org
Thu May 26 14:07:53 CEST 2011
http://hg.python.org/cpython/rev/01f84c4e581e
changeset: 70398:01f84c4e581e
user: Victor Stinner <victor.stinner at haypocalc.com>
date: Thu May 26 13:59:41 2011 +0200
summary:
zipimport: initialize fullpath to NULL
In some cases, fullpath value is used whereas fullpath was not always
initialized. Warning found by the Clang Static Analyzer.
files:
Modules/zipimport.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/Modules/zipimport.c b/Modules/zipimport.c
--- a/Modules/zipimport.c
+++ b/Modules/zipimport.c
@@ -1196,7 +1196,7 @@
int *p_ispackage, PyObject **p_modpath)
{
PyObject *code = NULL, *toc_entry, *subname;
- PyObject *path, *fullpath;
+ PyObject *path, *fullpath = NULL;
struct st_zip_searchorder *zso;
subname = get_subname(fullname);
--
Repository URL: http://hg.python.org/cpython
More information about the Python-checkins
mailing list