(Boeing r1782)

support tcl/tk8.6 when available
fix channel read error upon shutdown with tcl8.6
This commit is contained in:
ahrenholz 2013-10-09 19:57:45 +00:00
parent f28e80ab66
commit c85429ba8b
2 changed files with 6 additions and 2 deletions

View file

@ -75,7 +75,11 @@ proc receiveMessage { channel } {
# read first four bytes of message header
set more_data 1
while { $more_data == 1 } {
set bytes [read $channel 4]
if { [catch { set bytes [read $channel 4] } e] } {
# in tcl8.6 this occurs during shutdown
#puts "channel closed: $e"
break;
}
if { [fblocked $channel] == 1} {
# 4 bytes not available yet
break;