summaryrefslogtreecommitdiffstats
path: root/generic/tclIOCmd.c
diff options
context:
space:
mode:
authorKevin B Kenny <kennykb@acm.org>2007-04-24 02:42:18 (GMT)
committerKevin B Kenny <kennykb@acm.org>2007-04-24 02:42:18 (GMT)
commit146814b0108455aaaafda4e59a014c6e895d5cd1 (patch)
tree3dabb44a145009e9a5d1c9fb4f2cd52dcff62ce5 /generic/tclIOCmd.c
parentf5d116abda422caa1ca7f043400c43522b1fada7 (diff)
downloadtcl-146814b0108455aaaafda4e59a014c6e895d5cd1.zip
tcl-146814b0108455aaaafda4e59a014c6e895d5cd1.tar.gz
tcl-146814b0108455aaaafda4e59a014c6e895d5cd1.tar.bz2
* generic/tclIOCmd.c (Tcl_ReadObjCmd): Plugged a leak of the
buffer object if the physocal read returned an error and the bypass area had no message. * generic/tclIORChan.c (TclChanCreateObjCmd): Plugged a leak of the return value from the "initialize" method of a channel handler.
Diffstat (limited to 'generic/tclIOCmd.c')
-rw-r--r--generic/tclIOCmd.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/generic/tclIOCmd.c b/generic/tclIOCmd.c
index 542aeb6..97d11ff 100644
--- a/generic/tclIOCmd.c
+++ b/generic/tclIOCmd.c
@@ -8,7 +8,7 @@
* See the file "license.terms" for information on usage and redistribution of
* this file, and for a DISCLAIMER OF ALL WARRANTIES.
*
- * RCS: @(#) $Id: tclIOCmd.c,v 1.39 2007/04/02 18:48:03 dgp Exp $
+ * RCS: @(#) $Id: tclIOCmd.c,v 1.40 2007/04/24 02:42:18 kennykb Exp $
*/
#include "tclInt.h"
@@ -411,8 +411,8 @@ Tcl_ReadObjCmd(
Tcl_ResetResult(interp);
Tcl_AppendResult(interp, "error reading \"", name, "\": ",
Tcl_PosixError(interp), NULL);
- Tcl_DecrRefCount(resultPtr);
}
+ Tcl_DecrRefCount(resultPtr);
return TCL_ERROR;
}