wget can now be cancelled using ctrl-alt-c

This commit is contained in:
Izaya 2017-10-09 04:29:47 +11:00
parent e7f13d8767
commit 38f6982e39

View File

@ -14,6 +14,8 @@ if code ~= 200 then
end end
repeat repeat
coroutine.yield() coroutine.yield()
local t,c,C = event.get()
if t == "key" and c == 3 and C == 46 then break end
ns = R.read(2048) ns = R.read(2048)
f:write(ns or "") f:write(ns or "")
until not ns until not ns