summaryrefslogtreecommitdiffstats
path: root/Python/pylifecycle.c
diff options
context:
space:
mode:
Diffstat (limited to 'Python/pylifecycle.c')
-rw-r--r--Python/pylifecycle.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/Python/pylifecycle.c b/Python/pylifecycle.c
index 3c57056..ea84ca0 100644
--- a/Python/pylifecycle.c
+++ b/Python/pylifecycle.c
@@ -738,6 +738,7 @@ pycore_init_types(PyInterpreterState *interp)
if (_PyStatus_EXCEPTION(status)) {
return status;
}
+
return _PyStatus_OK();
}
@@ -854,6 +855,11 @@ pycore_interp_init(PyThreadState *tstate)
goto done;
}
+ status = _PyXI_Init(interp);
+ if (_PyStatus_EXCEPTION(status)) {
+ goto done;
+ }
+
const PyConfig *config = _PyInterpreterState_GetConfig(interp);
status = _PyImport_InitCore(tstate, sysmod, config->_install_importlib);
@@ -1772,6 +1778,7 @@ finalize_interp_clear(PyThreadState *tstate)
{
int is_main_interp = _Py_IsMainInterpreter(tstate->interp);
+ _PyXI_Fini(tstate->interp);
_PyExc_ClearExceptionGroupType(tstate->interp);
_Py_clear_generic_types(tstate->interp);