Accept a new socket connection
ns_sockaccept accepts a new connection pending on sockid.
#listen for connections on port 9000 set sock [ns_socklisten * 9000] #wait for new connection set fds [ns_sockaccept $sock] set rfd [lindex $fds 0] set wfd [lindex $fds 1] puts $wfd "Hello!" close $rfd close $wfd close $sock