Mercurial > forge
changeset 2111:3872fe327d32 octave-forge
Allow sync timing test from a separate host
author | pkienzle |
---|---|
date | Mon, 07 Nov 2005 20:45:38 +0000 |
parents | 158136e61df0 |
children | 78eb5c84e109 |
files | extra/soctcl/demo/octsync.tcl |
diffstat | 1 files changed, 3 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/extra/soctcl/demo/octsync.tcl Mon Nov 07 20:28:28 2005 +0000 +++ b/extra/soctcl/demo/octsync.tcl Mon Nov 07 20:45:38 2005 +0000 @@ -47,7 +47,9 @@ } } -set fd [socket localhost [lindex $argv 0]] +set hostport [split [lindex $argv 0] ":"] +if {[llength $hostport] == 1} { set hostport [list localhost $hostport] } +set fd [socket [lindex $hostport 0] [lindex $hostport 1]] fconfigure $fd -blocking true -buffering none -translation binary fileevent $fd readable [list recv $fd]