commit | 4a0d1e7c36f8ce2720fa6121b61bd048a87714ed | [log] [tgz] |
---|---|---|
author | Victor Stinner <victor.stinner@gmail.com> | Fri Sep 18 13:44:11 2015 +0200 |
committer | Victor Stinner <victor.stinner@gmail.com> | Fri Sep 18 13:44:11 2015 +0200 |
tree | 5e038d940e81ccf87d82c18eccf1a7ce89268c7f | |
parent | 9a8b177e60cc5cc6d5105519c0df8fb185211e1d [diff] |
odictobject.c: fix compiler warning PyObject_Length() returns a P_ssize_t, not an int. Use a Py_ssize_t to avoid overflow.
diff --git a/Objects/odictobject.c b/Objects/odictobject.c index 104d6c1..7df419e 100644 --- a/Objects/odictobject.c +++ b/Objects/odictobject.c
@@ -998,7 +998,7 @@ goto Done; else { PyObject *empty, *od_vars, *iterator, *key; - int ns_len; + Py_ssize_t ns_len; /* od.__dict__ isn't necessarily a dict... */ ns = PyObject_CallMethod((PyObject *)vars, "copy", NULL);