Issue #24115: Update uses of PyObject_IsTrue(), PyObject_Not(),

PyObject_IsInstance(), PyObject_RichCompareBool() and _PyDict_Contains()
to check for and handle errors correctly.
This commit is contained in:
Serhiy Storchaka 2015-05-30 17:48:19 +03:00
commit ac5569b1fa
10 changed files with 92 additions and 40 deletions

View file

@ -1115,8 +1115,8 @@ faulthandler_env_options(void)
has_key = PyDict_Contains(xoptions, key);
Py_DECREF(key);
if (!has_key)
return 0;
if (has_key <= 0)
return has_key;
}
module = PyImport_ImportModule("faulthandler");