summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authordgp <dgp@users.sourceforge.net>2006-11-29 15:01:25 (GMT)
committerdgp <dgp@users.sourceforge.net>2006-11-29 15:01:25 (GMT)
commit2044eda3d3d8e228ffb20840f511f8de39238b1f (patch)
tree74e4d180324cb623cd37caa94bb4db75ec38f21b
parentacf60973500b17458f07ae9f83c1fe5ebd93140f (diff)
downloadtcl-2044eda3d3d8e228ffb20840f511f8de39238b1f.zip
tcl-2044eda3d3d8e228ffb20840f511f8de39238b1f.tar.gz
tcl-2044eda3d3d8e228ffb20840f511f8de39238b1f.tar.bz2
* generic/tclBasic.c (Tcl_AppendObjToErrorInfo): Added
Tcl_DecrRefCount() on the objPtr argument to plug memory leaks. This makes the routine a consumer, which makes it easiest to use.
-rw-r--r--ChangeLog6
-rw-r--r--generic/tclBasic.c3
2 files changed, 8 insertions, 1 deletions
diff --git a/ChangeLog b/ChangeLog
index fefc447..1532983 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,9 @@
+2006-11-29 Don Porter <dgp@users.sourceforge.net>
+
+ * generic/tclBasic.c (Tcl_AppendObjToErrorInfo): Added
+ Tcl_DecrRefCount() on the objPtr argument to plug memory leaks.
+ This makes the routine a consumer, which makes it easiest to use.
+
2006-11-28 Andreas Kupries <andreask@activestate.com>
* generic/tclBasic.c: TIP #280 implementation.
diff --git a/generic/tclBasic.c b/generic/tclBasic.c
index ef01194..5df0a81 100644
--- a/generic/tclBasic.c
+++ b/generic/tclBasic.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: tclBasic.c,v 1.221 2006/11/28 22:20:27 andreas_kupries Exp $
+ * RCS: @(#) $Id: tclBasic.c,v 1.222 2006/11/29 15:01:26 dgp Exp $
*/
#include "tclInt.h"
@@ -5188,6 +5188,7 @@ Tcl_AppendObjToErrorInfo(
CONST char *message = Tcl_GetStringFromObj(objPtr, &length);
Tcl_AddObjErrorInfo(interp, message, length);
+ Tcl_DecrRefCount(objPtr);
}
/*