diff options
author | Miguel Sofer <miguel.sofer@gmail.com> | 2004-07-12 01:09:09 (GMT) |
---|---|---|
committer | Miguel Sofer <miguel.sofer@gmail.com> | 2004-07-12 01:09:09 (GMT) |
commit | 3824048c297c5067b5a813b3623378dc84a0b793 (patch) | |
tree | c29f0a1f5ab12c8641f13c5f30acf57f4eb81c84 /generic/tclParse.c | |
parent | 6570e4e99c3e50d63954e31e9c6810ed2f55698c (diff) | |
download | tcl-3824048c297c5067b5a813b3623378dc84a0b793.zip tcl-3824048c297c5067b5a813b3623378dc84a0b793.tar.gz tcl-3824048c297c5067b5a813b3623378dc84a0b793.tar.bz2 |
* generic/tclParse.c (Tcl_SubstObj): leak fix by dgp, release
result on error.
Diffstat (limited to 'generic/tclParse.c')
-rw-r--r-- | generic/tclParse.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/generic/tclParse.c b/generic/tclParse.c index 0d580b7..4d34448 100644 --- a/generic/tclParse.c +++ b/generic/tclParse.c @@ -13,7 +13,7 @@ * See the file "license.terms" for information on usage and redistribution * of this file, and for a DISCLAIMER OF ALL WARRANTIES. * - * RCS: @(#) $Id: tclParse.c,v 1.36 2004/04/06 22:25:54 dgp Exp $ + * RCS: @(#) $Id: tclParse.c,v 1.37 2004/07/12 01:09:10 msofer Exp $ */ #include "tclInt.h" @@ -1914,6 +1914,7 @@ Tcl_SubstObj(interp, objPtr, flags) Tcl_FreeParse(&parse); if (errMsg != NULL) { if (code != TCL_BREAK) { + Tcl_DecrRefCount(result); Tcl_SetObjResult(interp, errMsg); Tcl_DecrRefCount(errMsg); return NULL; |