[REBOL] Re: timeout
From: ptretter:charter at: 9-Apr-2001 20:56
here is an example script thats a port scanner (my intent is to make it much
more than that). Right now it has system/schemes/default/timeout: 1
However if you change it to 0:0.5 it responds much slower - why?
Title: "Port Scanner"
Author: "Paul Tretter"
host: Ask "Enter ip address or fully qualified hostname
port: to-integer Ask "Enter start port "
End: to-integer Ask "Enter End port "
newhost: rejoin [tcp:// host]
while [(end + 1) <> port][
getports: rejoin [newhost ":" port]
either error? error: try [open getports][
print ["nothing at port " port]
print ["port " port " available"]
port: port + 1