]> granicus.if.org Git - python/commitdiff
_PyObject_LookupSpecial returns a new reference
authorBenjamin Peterson <benjamin@python.org>
Sat, 5 Jun 2010 02:07:01 +0000 (02:07 +0000)
committerBenjamin Peterson <benjamin@python.org>
Sat, 5 Jun 2010 02:07:01 +0000 (02:07 +0000)
Objects/abstract.c

index 20d241ddc6880ac9f5b43f54d281b37c2ab31437..98d2dd0078405e6f3f7681f43ce7e79ff9e59c2b 100644 (file)
@@ -836,6 +836,7 @@ done1:
         }
         /* And call it. */
         result = PyObject_CallFunctionObjArgs(method, format_spec, NULL);
+        Py_DECREF(method);
     }
 
     if (result == NULL)