[Python-checkins] python/dist/src/Python bltinmodule.c,2.273,2.274
doerwalter@users.sourceforge.net
doerwalter@users.sourceforge.net
Tue, 04 Feb 2003 08:57:51 -0800
Update of /cvsroot/python/python/dist/src/Python
In directory sc8-pr-cvs1:/tmp/cvs-serv24350/Python
Modified Files:
bltinmodule.c
Log Message:
PyUnicode_Resize() doesn't free its argument in case of a failure,
so we can jump to the error handling code that does.
(Spotted by Neal Norwitz)
Index: bltinmodule.c
===================================================================
RCS file: /cvsroot/python/python/dist/src/Python/bltinmodule.c,v
retrieving revision 2.273
retrieving revision 2.274
diff -C2 -d -r2.273 -r2.274
*** bltinmodule.c 4 Feb 2003 16:28:00 -0000 2.273
--- bltinmodule.c 4 Feb 2003 16:57:49 -0000 2.274
***************
*** 2029,2033 ****
if (PyUnicode_Resize(&result, need)) {
Py_DECREF(item);
! return NULL;
}
outlen = need;
--- 2029,2033 ----
if (PyUnicode_Resize(&result, need)) {
Py_DECREF(item);
! goto Fail_1;
}
outlen = need;