Almost ready to release beta3
This commit is contained in:
parent
a8254e94f8
commit
97b26e0b66
23 changed files with 53 additions and 59 deletions
|
@ -12,13 +12,13 @@ if arg then
|
|||
port = arg[2] or port
|
||||
end
|
||||
host = socket.dns.toip(host)
|
||||
udp = socket.try(socket.udp())
|
||||
socket.try(udp:setpeername(host, port))
|
||||
udp = assert(socket.udp())
|
||||
assert(udp:setpeername(host, port))
|
||||
print("Using remote host '" ..host.. "' and port " .. port .. "...")
|
||||
while 1 do
|
||||
line = io.read()
|
||||
if not line then os.exit() end
|
||||
socket.try(udp:send(line))
|
||||
dgram = socket.try(udp:receive())
|
||||
if not line or line == "" then os.exit() end
|
||||
assert(udp:send(line))
|
||||
dgram = assert(udp:receive())
|
||||
print(dgram)
|
||||
end
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue