summaryrefslogtreecommitdiffhomepage
path: root/libs/sys/luasrc/sys.lua
diff options
context:
space:
mode:
Diffstat (limited to 'libs/sys/luasrc/sys.lua')
-rw-r--r--libs/sys/luasrc/sys.lua3
1 files changed, 2 insertions, 1 deletions
diff --git a/libs/sys/luasrc/sys.lua b/libs/sys/luasrc/sys.lua
index 66285249fc..df6280dda0 100644
--- a/libs/sys/luasrc/sys.lua
+++ b/libs/sys/luasrc/sys.lua
@@ -233,7 +233,8 @@ net = {}
-- The following fields are defined for arp entry objects:
-- { "IP address", "HW address", "HW type", "Flags", "Mask", "Device" }
function net.arptable(callback)
- local arp, e, r, v
+ local arp = (not callback) and {} or nil
+ local e, r, v
if fs.access("/proc/net/arp") then
for e in io.lines("/proc/net/arp") do
local r = { }, v