diff options
Diffstat (limited to 'Modules/_io/fileio.c')
-rw-r--r-- | Modules/_io/fileio.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/Modules/_io/fileio.c b/Modules/_io/fileio.c index 8ea7c58..ad4a7e6 100644 --- a/Modules/_io/fileio.c +++ b/Modules/_io/fileio.c @@ -240,7 +240,7 @@ fileio_init(PyObject *oself, PyObject *args, PyObject *kwds) return -1; } - fd = PyLong_AsLong(nameobj); + fd = _PyLong_AsInt(nameobj); if (fd < 0) { if (!PyErr_Occurred()) { PyErr_SetString(PyExc_ValueError, |