summaryrefslogtreecommitdiffstats
path: root/Modules/stropmodule.c
diff options
context:
space:
mode:
authorGuido van Rossum <guido@python.org>1998-10-19 13:38:36 (GMT)
committerGuido van Rossum <guido@python.org>1998-10-19 13:38:36 (GMT)
commitbf338300ff50bef79b774f0ab956db7cea260c80 (patch)
treea5cd111ea9045606b12de21dc84b531110ca7af0 /Modules/stropmodule.c
parent18fa7d280003beaab24a8e2b05a8226af73a4105 (diff)
downloadcpython-bf338300ff50bef79b774f0ab956db7cea260c80.zip
cpython-bf338300ff50bef79b774f0ab956db7cea260c80.tar.gz
cpython-bf338300ff50bef79b774f0ab956db7cea260c80.tar.bz2
Add a missing DECREF in an error exit. Submitted by Jonathan Giddy.
Diffstat (limited to 'Modules/stropmodule.c')
-rw-r--r--Modules/stropmodule.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/Modules/stropmodule.c b/Modules/stropmodule.c
index 3921d34..240a056 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;