Commit 5eb4f59c authored by Victor Stinner's avatar Victor Stinner

Issue #19437: Fix init_builtin(), handle _PyImport_FindExtensionObject()

failure
parent 46ef3195
......@@ -948,8 +948,12 @@ static int
init_builtin(PyObject *name)
{
struct _inittab *p;
PyObject *mod;
if (_PyImport_FindExtensionObject(name, name) != NULL)
mod = _PyImport_FindExtensionObject(name, name);
if (PyErr_Occurred())
return -1;
if (mod != NULL)
return 1;
for (p = PyImport_Inittab; p->name != NULL; p++) {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment