; this is to listen on port 123 for any connection and pass everything to the channel #file.lv ; will it work? proc serverOpen {channel addr port} { fileevent $channel readable "readLine Server $channel" } proc readLine {who channel} { if {[gets $channel line]<0} { ;what do the following two lines do? fileevent $channel readable {} after idle "close $channel;set out 1" } else { putquick "PRIVMSG #file.lv : $line" flush $channel; } } # catch {socket -server serverOpen 123} server set server [socket -server serverOpen 123]