[Python-checkins] CVS: python/dist/src/Modules mmapmodule.c,2.15,2.16
Guido van Rossum
python-dev@python.org
Fri, 30 Jun 2000 17:51:54 -0700
Update of /cvsroot/python/python/dist/src/Modules
In directory slayer.i.sourceforge.net:/tmp/cvs-serv17467
Modified Files:
mmapmodule.c
Log Message:
clean up warnings in Win32 build of mmapmodule.c
Index: mmapmodule.c
===================================================================
RCS file: /cvsroot/python/python/dist/src/Modules/mmapmodule.c,v
retrieving revision 2.15
retrieving revision 2.16
diff -C2 -r2.15 -r2.16
*** mmapmodule.c 2000/06/18 19:06:49 2.15
--- mmapmodule.c 2000/07/01 00:51:51 2.16
***************
*** 569,573 ****
{
CHECK_VALID(NULL);
! if (i < 0 || i >= self->size) {
PyErr_SetString(PyExc_IndexError, "mmap index out of range");
return NULL;
--- 569,573 ----
{
CHECK_VALID(NULL);
! if (i < 0 || (size_t)i >= self->size) {
PyErr_SetString(PyExc_IndexError, "mmap index out of range");
return NULL;
***************
*** 584,588 ****
if (ilow < 0)
ilow = 0;
! else if (ilow > self->size)
ilow = self->size;
if (ihigh < 0)
--- 584,588 ----
if (ilow < 0)
ilow = 0;
! else if ((size_t)ilow > self->size)
ilow = self->size;
if (ihigh < 0)
***************
*** 590,594 ****
if (ihigh < ilow)
ihigh = ilow;
! else if (ihigh > self->size)
ihigh = self->size;
--- 590,594 ----
if (ihigh < ilow)
ihigh = ilow;
! else if ((size_t)ihigh > self->size)
ihigh = self->size;
***************
*** 629,633 ****
if (ilow < 0)
ilow = 0;
! else if (ilow > self->size)
ilow = self->size;
if (ihigh < 0)
--- 629,633 ----
if (ilow < 0)
ilow = 0;
! else if ((size_t)ilow > self->size)
ilow = self->size;
if (ihigh < 0)
***************
*** 635,639 ****
if (ihigh < ilow)
ihigh = ilow;
! else if (ihigh > self->size)
ihigh = self->size;
--- 635,639 ----
if (ihigh < ilow)
ihigh = ilow;
! else if ((size_t)ihigh > self->size)
ihigh = self->size;
***************
*** 662,666 ****
CHECK_VALID(-1);
! if (i < 0 || i >= self->size) {
PyErr_SetString(PyExc_IndexError, "mmap index out of range");
return -1;
--- 662,666 ----
CHECK_VALID(-1);
! if (i < 0 || (size_t)i >= self->size) {
PyErr_SetString(PyExc_IndexError, "mmap index out of range");
return -1;