diff options
author | Martin v. Löwis <martin@v.loewis.de> | 2006-02-16 14:30:23 +0000 |
---|---|---|
committer | Martin v. Löwis <martin@v.loewis.de> | 2006-02-16 14:30:23 +0000 |
commit | ad0a4629beac0600c4c4c3167b0d68be57ca674e (patch) | |
tree | a4aef28fd7dbf93c7dabde51ce88fe1748e29427 /Modules/cStringIO.c | |
parent | 97c65a8068056863215eb3a14024c1e4a8d19b9f (diff) | |
download | cpython-git-ad0a4629beac0600c4c4c3167b0d68be57ca674e.tar.gz |
Use Py_ssize_t for counts and sizes.
Diffstat (limited to 'Modules/cStringIO.c')
-rw-r--r-- | Modules/cStringIO.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/Modules/cStringIO.c b/Modules/cStringIO.c index 618b88c69a..0b4faa3881 100644 --- a/Modules/cStringIO.c +++ b/Modules/cStringIO.c @@ -129,7 +129,7 @@ IO_cgetval(PyObject *self) { static PyObject * IO_getval(IOobject *self, PyObject *args) { PyObject *use_pos=Py_None; - int s; + Py_ssize_t s; UNLESS (IO__opencheck(self)) return NULL; UNLESS (PyArg_UnpackTuple(args,"getval", 0, 1,&use_pos)) return NULL; @@ -156,7 +156,7 @@ PyDoc_STRVAR(IO_read__doc__, static int IO_cread(PyObject *self, char **output, Py_ssize_t n) { - int l; + Py_ssize_t l; UNLESS (IO__opencheck(IOOOBJECT(self))) return -1; l = ((IOobject*)self)->string_size - ((IOobject*)self)->pos; @@ -279,7 +279,7 @@ IO_tell(IOobject *self, PyObject *unused) { UNLESS (IO__opencheck(self)) return NULL; - return PyInt_FromLong(self->pos); + return PyInt_FromSsize_t(self->pos); } PyDoc_STRVAR(IO_truncate__doc__, |