mirror of
https://github.com/AdaCore/cpython.git
synced 2026-02-12 12:57:15 -08:00
Issue #27909: Fix INCREF for possible NULL value
This commit is contained in:
@@ -1056,7 +1056,7 @@ _imp_create_builtin(PyObject *module, PyObject *spec)
|
||||
mod = _PyImport_FindExtensionObject(name, name);
|
||||
if (mod || PyErr_Occurred()) {
|
||||
Py_DECREF(name);
|
||||
Py_INCREF(mod);
|
||||
Py_XINCREF(mod);
|
||||
return mod;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user