summaryrefslogtreecommitdiffstats
path: root/Modules/posixmodule.c
diff options
context:
space:
mode:
authorMartin v. Löwis <martin@v.loewis.de>2006-04-22 11:15:41 (GMT)
committerMartin v. Löwis <martin@v.loewis.de>2006-04-22 11:15:41 (GMT)
commit26fd9607c729f4dbe322967464834a2bce18c07d (patch)
treedbe8e2a9ce2960e77a99a8df198795b82ad38555 /Modules/posixmodule.c
parent8694a6db0e590887c5e43eb949481935f89de424 (diff)
downloadcpython-26fd9607c729f4dbe322967464834a2bce18c07d.zip
cpython-26fd9607c729f4dbe322967464834a2bce18c07d.tar.gz
cpython-26fd9607c729f4dbe322967464834a2bce18c07d.tar.bz2
Fix more ssize_t problems.
Diffstat (limited to 'Modules/posixmodule.c')
-rw-r--r--Modules/posixmodule.c12
1 files changed, 7 insertions, 5 deletions
diff --git a/Modules/posixmodule.c b/Modules/posixmodule.c
index b51ba5d..816e3eb 100644
--- a/Modules/posixmodule.c
+++ b/Modules/posixmodule.c
@@ -2440,7 +2440,7 @@ posix_execve(PyObject *self, PyObject *args)
PyObject *key, *val, *keys=NULL, *vals=NULL;
Py_ssize_t i, pos, argc, envc;
PyObject *(*getitem)(PyObject *, Py_ssize_t);
- int lastarg = 0;
+ Py_ssize_t lastarg = 0;
/* execve has three arguments: (path, argv, env), where
argv is a list or tuple of strings and env is a dictionary
@@ -2581,7 +2581,8 @@ posix_spawnv(PyObject *self, PyObject *args)
char *path;
PyObject *argv;
char **argvlist;
- int mode, i, argc;
+ int mode, i;
+ Py_ssize_t argc;
Py_intptr_t spawnval;
PyObject *(*getitem)(PyObject *, Py_ssize_t);
@@ -2670,10 +2671,11 @@ posix_spawnve(PyObject *self, PyObject *args)
char **argvlist;
char **envlist;
PyObject *key, *val, *keys=NULL, *vals=NULL, *res=NULL;
- int mode, i, pos, argc, envc;
+ int mode, pos, envc;
+ Py_ssize_t argc, i;
Py_intptr_t spawnval;
PyObject *(*getitem)(PyObject *, Py_ssize_t);
- int lastarg = 0;
+ Py_ssize_t lastarg = 0;
/* spawnve has four arguments: (mode, path, argv, env), where
argv is a list or tuple of strings and env is a dictionary
@@ -4374,7 +4376,7 @@ _PyPopenCreateProcess(char *cmdstring,
char modulepath[_MAX_PATH];
struct stat statinfo;
GetModuleFileName(NULL, modulepath, sizeof(modulepath));
- for (i = x = 0; modulepath[i]; i++)
+ for (x = i = 0; modulepath[i]; i++)
if (modulepath[i] == SEP)
x = i+1;
modulepath[x] = '\0';