mirror of
https://github.com/python/cpython.git
synced 2025-11-03 03:22:27 +00:00
Closure can't be NULL at this point since we know it's a tuple.
Reported by Klocwork # 74.
This commit is contained in:
parent
e4abc232d5
commit
101bac205d
1 changed files with 1 additions and 1 deletions
|
|
@ -141,7 +141,7 @@ PyFunction_SetClosure(PyObject *op, PyObject *closure)
|
|||
if (closure == Py_None)
|
||||
closure = NULL;
|
||||
else if (PyTuple_Check(closure)) {
|
||||
Py_XINCREF(closure);
|
||||
Py_INCREF(closure);
|
||||
}
|
||||
else {
|
||||
PyErr_Format(PyExc_SystemError,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue