summaryrefslogtreecommitdiffstats
path: root/Python/marshal.c
diff options
context:
space:
mode:
authorSerhiy Storchaka <storchaka@gmail.com>2015-02-16 18:52:17 (GMT)
committerSerhiy Storchaka <storchaka@gmail.com>2015-02-16 18:52:17 (GMT)
commit26861b0b29fdf64fba8cd120183408495f2c80e2 (patch)
tree68aa9e4560327db352dcbda56bf3ea0325bde0f7 /Python/marshal.c
parent4d0d9829851915e97ae392dd803976be6c95c8d1 (diff)
downloadcpython-26861b0b29fdf64fba8cd120183408495f2c80e2.zip
cpython-26861b0b29fdf64fba8cd120183408495f2c80e2.tar.gz
cpython-26861b0b29fdf64fba8cd120183408495f2c80e2.tar.bz2
Issue #23450: Fixed possible integer overflows.
Diffstat (limited to 'Python/marshal.c')
-rw-r--r--Python/marshal.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/Python/marshal.c b/Python/marshal.c
index c1ce2fe..d26a997 100644
--- a/Python/marshal.c
+++ b/Python/marshal.c
@@ -279,7 +279,7 @@ w_ref(PyObject *v, char *flag, WFILE *p)
PyErr_SetString(PyExc_ValueError, "too many objects");
goto err;
}
- w = s;
+ w = (int)s;
Py_INCREF(v);
if (_Py_HASHTABLE_SET(p->hashtable, v, w) < 0) {
Py_DECREF(v);