made the parsing not die with no input

This commit is contained in:
Izaya 2018-04-17 01:16:03 +10:00
parent c886e27774
commit 75b5d832ca
1 changed files with 3 additions and 1 deletions

View File

@ -16,7 +16,9 @@ local katimer
function start(faddr)
if listener then return end
local host,nport = faddr:match("(.+):(%d+)")
if faddr then
local host,nport = faddr:match("(.+):(%d+)")
end
local iaddr,port = host or faddr or "shadowkat.net", tonumber(nport) or 4096
socket = internet.connect(iaddr,port)
print("Connecting to "..iaddr..":"..tostring(port).."...")