mirror of
https://github.com/radio95-rnt/rds95.git
synced 2026-02-26 20:33:53 +01:00
error msg
This commit is contained in:
@@ -1,11 +1,11 @@
|
||||
function data_handle(data)
|
||||
if string.sub(data, 1, 4):lower() == "lua=" then
|
||||
local chunk, err = load(string.sub(data, 5), "udp_chunk") -- skip "lua="
|
||||
if not chunk then return "-" end
|
||||
if not chunk then return string.format("-\r\n%s\r\n", err) end
|
||||
return tostring(chunk())
|
||||
elseif string.sub(data, 1, 5):lower() == "file=" then
|
||||
local chunk, err = loadfile(data:sub(6)) -- skip "file="
|
||||
if not chunk then return "-" end
|
||||
if not chunk then return string.format("-\r\n%s\r\n", err) end
|
||||
return tostring(chunk())
|
||||
end
|
||||
|
||||
|
||||
Reference in New Issue
Block a user