diff options
Diffstat (limited to 'Python/modsupport.c')
-rw-r--r-- | Python/modsupport.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/Python/modsupport.c b/Python/modsupport.c index 7dbfe1c..dacc1a0 100644 --- a/Python/modsupport.c +++ b/Python/modsupport.c @@ -47,6 +47,8 @@ Py_InitModule4(char *name, PyMethodDef *methods, char *doc, { PyObject *m, *d, *v; PyMethodDef *ml; + if (!Py_IsInitialized()) + Py_FatalError("Interpreter not initialized (version mismatch?)"); if (module_api_version != PYTHON_API_VERSION) fprintf(stderr, api_version_warning, name, PYTHON_API_VERSION, name, module_api_version); |