summaryrefslogtreecommitdiffstats
path: root/Modules/_randommodule.c
diff options
context:
space:
mode:
authorMark Dickinson <dickinsm@gmail.com>2009-05-05 17:54:36 (GMT)
committerMark Dickinson <dickinsm@gmail.com>2009-05-05 17:54:36 (GMT)
commit9cc2cf78ad9ae38fbe56e7e4c3a9d6f0a4a4104f (patch)
treeb6a87d250741ef9f2b44a6a19850c4224ab4b110 /Modules/_randommodule.c
parent3bef15be2d997124efc8cafca0e17aaf07a386dc (diff)
downloadcpython-9cc2cf78ad9ae38fbe56e7e4c3a9d6f0a4a4104f.zip
cpython-9cc2cf78ad9ae38fbe56e7e4c3a9d6f0a4a4104f.tar.gz
cpython-9cc2cf78ad9ae38fbe56e7e4c3a9d6f0a4a4104f.tar.bz2
Merged revisions 72344 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/trunk ........ r72344 | mark.dickinson | 2009-05-05 18:41:47 +0100 (Tue, 05 May 2009) | 3 lines Issue #5933: Fix some gcc -Wextra warnings. Thanks Victor Stinner for the patch. ........
Diffstat (limited to 'Modules/_randommodule.c')
-rw-r--r--Modules/_randommodule.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/Modules/_randommodule.c b/Modules/_randommodule.c
index 2718b69..05c09d8 100644
--- a/Modules/_randommodule.c
+++ b/Modules/_randommodule.c
@@ -355,7 +355,7 @@ random_setstate(RandomObject *self, PyObject *state)
for (i=0; i<N ; i++) {
element = PyLong_AsUnsignedLong(PyTuple_GET_ITEM(state, i));
- if (element == -1 && PyErr_Occurred())
+ if (element == (unsigned long)-1 && PyErr_Occurred())
return NULL;
self->state[i] = element & 0xffffffffUL; /* Make sure we get sane state */
}