Limits the maximum number of nIndex interfaces

This commit is contained in:
Simone Mainardi 2018-12-21 17:41:03 +01:00
parent 90437eef23
commit 55a05c2bb7
7 changed files with 34 additions and 9 deletions

View file

@ -745,10 +745,12 @@ function hasNindexSupport()
if prefs == nil then
prefs = ntop.getPrefs()
end
local rc = prefs.is_nindex_enabled
if(rc == nil) then rc = false end
return rc
if prefs.is_nindex_enabled and interface.nIndexEnabled() then
return true
end
return false
end
--for _key, _value in pairsByKeys(vals, rev) do