diff options
author | Georg Brandl <georg@python.org> | 2006-06-04 21:46:16 (GMT) |
---|---|---|
committer | Georg Brandl <georg@python.org> | 2006-06-04 21:46:16 (GMT) |
commit | 9f167606665c186179bf362d4227e722731cd1b9 (patch) | |
tree | 1ab8469f32eba313583f23ed89babdce88040d2f /Objects/unicodeobject.c | |
parent | 3f767795f6784ca6bf797b055be67fce5bf2fa06 (diff) | |
download | cpython-9f167606665c186179bf362d4227e722731cd1b9.zip cpython-9f167606665c186179bf362d4227e722731cd1b9.tar.gz cpython-9f167606665c186179bf362d4227e722731cd1b9.tar.bz2 |
Repair refleaks in unicodeobject.
Diffstat (limited to 'Objects/unicodeobject.c')
-rw-r--r-- | Objects/unicodeobject.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/Objects/unicodeobject.c b/Objects/unicodeobject.c index eb5bdd8..970e69f 100644 --- a/Objects/unicodeobject.c +++ b/Objects/unicodeobject.c @@ -3194,6 +3194,8 @@ PyUnicode_BuildEncodingMap(PyObject* string) goto failed1; if (PyDict_SetItem(result, key, value) == -1) goto failed1; + Py_DECREF(key); + Py_DECREF(value); } return result; failed1: @@ -3389,6 +3391,7 @@ charmapencode_result charmapencode_output(Py_UNICODE c, PyObject *mapping, *outpos += repsize; } } + Py_DECREF(rep); return enc_SUCCESS; } |