summaryrefslogtreecommitdiffstats
path: root/Objects/unicodeobject.c
diff options
context:
space:
mode:
authorMarc-André Lemburg <mal@egenix.com>2002-05-29 13:46:29 (GMT)
committerMarc-André Lemburg <mal@egenix.com>2002-05-29 13:46:29 (GMT)
commit41644392407eadb07dd09a08e5d316c4edf3fcbb (patch)
tree1d4c397f1d3d9199fca938b89e6ac7f5ff0f62e1 /Objects/unicodeobject.c
parent4da6fd63bc431468e9622341ac410c55a54c7b9b (diff)
downloadcpython-41644392407eadb07dd09a08e5d316c4edf3fcbb.zip
cpython-41644392407eadb07dd09a08e5d316c4edf3fcbb.tar.gz
cpython-41644392407eadb07dd09a08e5d316c4edf3fcbb.tar.bz2
Fix a possible segfault. Found be Neal Norvitz.
Diffstat (limited to 'Objects/unicodeobject.c')
-rw-r--r--Objects/unicodeobject.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/Objects/unicodeobject.c b/Objects/unicodeobject.c
index e24453d..2cb97bc 100644
--- a/Objects/unicodeobject.c
+++ b/Objects/unicodeobject.c
@@ -2890,7 +2890,7 @@ int PyUnicode_Find(PyObject *str,
return -2;
substr = PyUnicode_FromObject(substr);
if (substr == NULL) {
- Py_DECREF(substr);
+ Py_DECREF(str);
return -2;
}