From 101bac205d6938316872b74201c4c6efe2bce340 Mon Sep 17 00:00:00 2001 From: Neal Norwitz Date: Thu, 27 Jul 2006 03:55:39 +0000 Subject: [PATCH] Closure can't be NULL at this point since we know it's a tuple. Reported by Klocwork # 74. --- Objects/funcobject.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Objects/funcobject.c b/Objects/funcobject.c index e514eeb2d3..1ba74c5a92 100644 --- a/Objects/funcobject.c +++ b/Objects/funcobject.c @@ -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, -- 2.50.1