SF patch #708201, unchecked return value in import.c by Jason Harper
Will backport.
This commit is contained in:
parent
29fd2baf82
commit
a11e4c13b1
|
@ -1924,6 +1924,8 @@ PyImport_ImportModule(char *name)
|
|||
PyObject *result;
|
||||
|
||||
pname = PyString_FromString(name);
|
||||
if (pname == NULL)
|
||||
return NULL;
|
||||
result = PyImport_Import(pname);
|
||||
Py_DECREF(pname);
|
||||
return result;
|
||||
|
|
Loading…
Reference in New Issue