commit | 3f528f0c1b79f32b1c00348f53f4b5b2007f16c5 | [log] [tgz] |
---|---|---|
author | Victor Stinner <victor.stinner@haypocalc.com> | Tue Oct 11 22:28:56 2011 +0200 |
committer | Victor Stinner <victor.stinner@haypocalc.com> | Tue Oct 11 22:28:56 2011 +0200 |
tree | a76bfcf24fcaf2f2367eef113b8da4783f82c0fd | |
parent | 8c9818980b639d4f50d0fb95ee383565e7dfa171 [diff] [blame] |
Fix a compiler warning in zipimport
diff --git a/Modules/zipimport.c b/Modules/zipimport.c index 3c07866..87dc0db 100644 --- a/Modules/zipimport.c +++ b/Modules/zipimport.c
@@ -868,7 +868,7 @@ PY_MAJOR_VERSION, PY_MINOR_VERSION); goto error; } - for (i = 0; (i < MAXPATHLEN - length - 1) && + for (i = 0; (i < (MAXPATHLEN - (Py_ssize_t)length - 1)) && (i < PyUnicode_GET_LENGTH(nameobj)); i++) path[length + 1 + i] = PyUnicode_READ_CHAR(nameobj, i); path[length + 1 + i] = 0;