diff Objects/unicodeobject.c @ 30165:4708fa086121 2.3

Backport checkin: Fix refcounting leak in charmaptranslate_lookup()
author Walter Dörwald <walter@livinglogic.de>
date Fri, 15 Aug 2003 16:52:33 +0000
parents 29b1d0763790
children 7ab1a41f16da
line wrap: on
line diff
--- a/Objects/unicodeobject.c	Fri Aug 15 16:27:32 2003 +0000
+++ b/Objects/unicodeobject.c	Fri Aug 15 16:52:33 2003 +0000
@@ -3202,6 +3202,7 @@
 	/* wrong return value */
 	PyErr_SetString(PyExc_TypeError,
 	      "character mapping must return integer, None or unicode");
+	Py_DECREF(x);
 	return -1;
     }
 }