summaryrefslogtreecommitdiffstats
path: root/Modules/_io/_iomodule.c
diff options
context:
space:
mode:
Diffstat (limited to 'Modules/_io/_iomodule.c')
-rw-r--r--Modules/_io/_iomodule.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/Modules/_io/_iomodule.c b/Modules/_io/_iomodule.c
index af5950c..175fa97 100644
--- a/Modules/_io/_iomodule.c
+++ b/Modules/_io/_iomodule.c
@@ -10,6 +10,7 @@
#define PY_SSIZE_T_CLEAN
#include "Python.h"
#include "_iomodule.h"
+#include "pycore_moduleobject.h" // _PyModule_GetState()
#include "pycore_pystate.h" // _PyInterpreterState_GET()
#ifdef HAVE_SYS_TYPES_H
@@ -560,7 +561,7 @@ PyNumber_AsOff_t(PyObject *item, PyObject *err)
static inline _PyIO_State*
get_io_state(PyObject *module)
{
- void *state = PyModule_GetState(module);
+ void *state = _PyModule_GetState(module);
assert(state != NULL);
return (_PyIO_State *)state;
}