diff --git a/package/gluon-mesh-vpn-tunneldigger/files/usr/bin/tunneldigger-watchdog b/package/gluon-mesh-vpn-tunneldigger/files/usr/bin/tunneldigger-watchdog index 1e3022e0..c387f013 100755 --- a/package/gluon-mesh-vpn-tunneldigger/files/usr/bin/tunneldigger-watchdog +++ b/package/gluon-mesh-vpn-tunneldigger/files/usr/bin/tunneldigger-watchdog @@ -16,16 +16,16 @@ function read_pid_file() end function check_for_mesh_vpn_neighbours() - local handle_batctl = io.popen("batctl o", 'r') - if handle_batctl~=nil then - for line in handle_batctl:lines() do + local handle = io.popen("batctl o", 'r') + if handle~=nil then + for line in handle:lines() do if line:find('mesh%-vpn') then - handle_batctl:close() + handle:close() return true end end end - handle_batctl:close() + handle:close() return false end