Tcl Library Source Code

View Ticket
Login
Ticket UUID: 1438365
Title: possible error condition when port in use
Type: Bug Version: None
Submitter: cuasimoes Created on: 2006-02-24 21:45:40
Subsystem: comm Assigned To: andreas_kupries
Priority: 5 Medium Severity:
Status: Open Last Modified: 2006-02-24 21:45:40
Resolution: None Closed By:
    Closed on:
Description:
In line 632, there is a possible error condition with
the command "rename $chan {}". 

I've run into a case (with a user-defined port and
channel) in which the user-defined port is in use (by
an outside application), but the channel doesn't exist.
In this case, the "rename $chan {}" errors out:
can't delete "::test": command doesn't exist.

But the real error should be that the port is already
in use (line 634).

This can be fixed by verifying that the channel exists
before trying to do a rename (in line 631 for example).