summaryrefslogtreecommitdiffstats
path: root/Modules
diff options
context:
space:
mode:
Diffstat (limited to 'Modules')
-rw-r--r--Modules/zipimport.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/Modules/zipimport.c b/Modules/zipimport.c
index 3b8eb93..91b8488 100644
--- a/Modules/zipimport.c
+++ b/Modules/zipimport.c
@@ -61,14 +61,15 @@ static int
zipimporter_init(ZipImporter *self, PyObject *args, PyObject *kwds)
{
char *path, *p, *prefix, buf[MAXPATHLEN+2];
- Py_ssize_t len;
+ size_t len;
if (!_PyArg_NoKeywords("zipimporter()", kwds))
return -1;
- if (!PyArg_ParseTuple(args, "s#:zipimporter", &path, &len))
+ if (!PyArg_ParseTuple(args, "s:zipimporter", &path))
return -1;
+ len = strlen(path);
if (len == 0) {
PyErr_SetString(ZipImportError, "archive path is empty");
return -1;