diff options
author | Serhiy Storchaka <storchaka@gmail.com> | 2015-09-06 21:25:30 +0300 |
---|---|---|
committer | Serhiy Storchaka <storchaka@gmail.com> | 2015-09-06 21:25:30 +0300 |
commit | 51dfb6f71adbaf1e1d68ecacdfcf4a77be02e246 (patch) | |
tree | 269deaf808e88e1015408b3e11e920cd2900b890 /Python/Python-ast.c | |
parent | abe3e1eb0d757e661158661bee7e1b678cb0380f (diff) | |
download | cpython-51dfb6f71adbaf1e1d68ecacdfcf4a77be02e246.tar.gz |
Issue #15989: Fixed some scarcely probable integer overflows.
It is very unlikely that they can occur in real code for now.
Diffstat (limited to 'Python/Python-ast.c')
-rw-r--r-- | Python/Python-ast.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/Python/Python-ast.c b/Python/Python-ast.c index 8a2dc7cc54..fd7f17e85b 100644 --- a/Python/Python-ast.c +++ b/Python/Python-ast.c @@ -769,7 +769,7 @@ static int obj2ast_int(PyObject* obj, int* out, PyArena* arena) return 1; } - i = (int)PyLong_AsLong(obj); + i = _PyLong_AsInt(obj); if (i == -1 && PyErr_Occurred()) return 1; *out = i; |