summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-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);
}
/*