RE: [tkined] side effect in Tcl_NotifyChannel introduced in tcl8.

Dukhovni, Viktor (Viktor-Dukhovni@deshaw.com)
Mon, 14 Sep 1998 12:44:20 -0400

> -----Original Message-----
> From: Juergen Schoenwaelder [SMTP:schoenw@ibr.cs.tu-bs.de]
> Sent: Monday, September 14, 1998 4:23 AM
> To: bugs@scriptics.com
> Cc: tkined@ibr.cs.tu-bs.de
> Subject: [tkined] side effect in Tcl_NotifyChannel introduced in
> tcl8.0.3
>
>
> Question:
>
> Do you agree that this is a bug? If yes, when can we expect the next
> official patch which corrects the problem? (I have to decide whether I
> have to rewrite my code to work around the problem or if I can expect
> a fixed version of Tcl and TclPro soon. Thanks,
>
Juergen,

The 8.0.3 code is I believe correct. Tcl needs to protect channels
around fileevent callbacks, and needs to complete of any channels that were
closed in the callback once the channel is no longer needed by the code that
dispatches the event.

I use Tnm 3.0.0 980501 and have not yet run into the problem you
describe could be a little more specific as to were in the Tnm code the
problem arises.

The best fix is to also call Tcl_RegisterChannel((Tcl_Interp *)NULL,
channel) in your code, and call Tcl_UnregisterChannel() instead of
Tcl_Close() to close the channel.

--
Viktor.

--
!! This message is brought to you via the `tkined & scotty' mailing list.
!! Please do not reply to this message to unsubscribe. To subscribe or
!! unsubscribe, send a mail message to <tkined-request@ibr.cs.tu-bs.de>.
!! See http://wwwsnmp.cs.utwente.nl/~schoenw/scotty/ for more information.