From bf338300ff50bef79b774f0ab956db7cea260c80 Mon Sep 17 00:00:00 2001 From: Guido van Rossum Date: Mon, 19 Oct 1998 13:38:36 +0000 Subject: [PATCH] Add a missing DECREF in an error exit. Submitted by Jonathan Giddy. --- Modules/stropmodule.c | 1 + 1 file changed, 1 insertion(+) diff --git a/Modules/stropmodule.c b/Modules/stropmodule.c index 3921d3460eb..240a056f6f3 100644 --- a/Modules/stropmodule.c +++ b/Modules/stropmodule.c @@ -228,6 +228,7 @@ strop_joinfields(self, args) if (item && !PyString_Check(item)) { PyErr_SetString(PyExc_TypeError, "first argument must be sequence of strings"); + Py_DECREF(item); return NULL; } return item;