summaryrefslogtreecommitdiffstats
path: root/Modules
diff options
context:
space:
mode:
authorTim Peters <tim.peters@gmail.com>2006-02-17 01:07:39 (GMT)
committerTim Peters <tim.peters@gmail.com>2006-02-17 01:07:39 (GMT)
commitf28829577d229ba6b89e2a574da09d9fe2152460 (patch)
treee518ecf313fc74b2991494173946b72e47b02def /Modules
parent8f9cc29e74f19674a0c54eaf74c2fde9ecafbe75 (diff)
downloadcpython-f28829577d229ba6b89e2a574da09d9fe2152460.zip
cpython-f28829577d229ba6b89e2a574da09d9fe2152460.tar.gz
cpython-f28829577d229ba6b89e2a574da09d9fe2152460.tar.bz2
mmap_flush_method(): Squash compiler warning about
mixing signed and unsigned types in comparison.
Diffstat (limited to 'Modules')
-rw-r--r--Modules/mmapmodule.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/Modules/mmapmodule.c b/Modules/mmapmodule.c
index 58d74e6..b777eff 100644
--- a/Modules/mmapmodule.c
+++ b/Modules/mmapmodule.c
@@ -471,9 +471,9 @@ mmap_flush_method(mmap_object *self, PyObject *args)
Py_ssize_t offset = 0;
Py_ssize_t size = self->size;
CHECK_VALID(NULL);
- if (!PyArg_ParseTuple(args, "|nn:flush", &offset, &size)) {
+ if (!PyArg_ParseTuple(args, "|nn:flush", &offset, &size))
return NULL;
- } else if ((offset + size) > self->size) {
+ if ((size_t)(offset + size) > self->size) {
PyErr_SetString(PyExc_ValueError, "flush values out of range");
return NULL;
} else {