mirror of
https://github.com/ntop/ntopng.git
synced 2026-04-29 23:49:33 +00:00
Add check for periodic scripts changing the interface
This commit is contained in:
parent
55df85e4e0
commit
2ff83bcdc3
4 changed files with 14 additions and 6 deletions
|
|
@ -2321,6 +2321,12 @@ local function runSystemChecks(granularity, checks_var, do_trace)
|
|||
entity_info = info,
|
||||
ts_enabled = checks_var.system_ts_enabled
|
||||
})
|
||||
|
||||
-- Safety check
|
||||
if interface.getId() ~= tonumber(getSystemInterfaceId()) then
|
||||
traceError(TRACE_ERROR, TRACE_CONSOLE, string.format("Script '%s' changed the interface from '%d' to '%d'. Resetting interface.", mod_key, tonumber(getSystemInterfaceId()), interface.getId()))
|
||||
interface.select(getSystemInterfaceId())
|
||||
end
|
||||
end
|
||||
end
|
||||
end
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue