diff options
author | Raymond Hettinger <python@rcn.com> | 2016-08-31 15:44:11 (GMT) |
---|---|---|
committer | Raymond Hettinger <python@rcn.com> | 2016-08-31 15:44:11 (GMT) |
commit | f0afe77c52971e17e559ae4e7889bf353fccffb5 (patch) | |
tree | 3eec7e7427faa42f06cecb10ce015405528c6875 /Python | |
parent | 74eda76085036d836041e616332ef3257d0172d3 (diff) | |
download | cpython-f0afe77c52971e17e559ae4e7889bf353fccffb5.zip cpython-f0afe77c52971e17e559ae4e7889bf353fccffb5.tar.gz cpython-f0afe77c52971e17e559ae4e7889bf353fccffb5.tar.bz2 |
Issue #27909: Fix INCREF for possible NULL value
Diffstat (limited to 'Python')
-rw-r--r-- | Python/import.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/Python/import.c b/Python/import.c index 5025e75..7018d59 100644 --- a/Python/import.c +++ b/Python/import.c @@ -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; } |