323b045b4b
``while 1 { close [open /dev/null r] }'' does not leak memory for each go-around. This corresponds to sourceforge bugid #117988. Bump PKGNAME to tcl-8.3.2nb1.
19 lines
665 B
Text
19 lines
665 B
Text
$NetBSD: patch-ad,v 1.1 2001/01/24 18:42:33 he Exp $
|
|
|
|
--- ../generic/tclIO.c.orig Tue Aug 8 02:57:40 2000
|
|
+++ ../generic/tclIO.c Wed Jan 24 16:28:20 2001
|
|
@@ -2181,10 +2181,13 @@
|
|
|
|
/*
|
|
* There is only the TOP Channel, so we free the remaining
|
|
- * pointers we have and then ourselves.
|
|
+ * pointers we have and then ourselves. Since this is the
|
|
+ * last of the channels in the stack, make sure to free the
|
|
+ * ChannelState structure associated with it.
|
|
*/
|
|
chanPtr->typePtr = NULL;
|
|
|
|
+ Tcl_EventuallyFree((ClientData) statePtr, TCL_DYNAMIC);
|
|
Tcl_EventuallyFree((ClientData) chanPtr, TCL_DYNAMIC);
|
|
|
|
return errorCode;
|