mirror of
https://github.com/ntop/ntopng.git
synced 2026-05-03 01:10:10 +00:00
moved interface.getStats call in periodic scripts to avoid that the current interface is changed by (unexpected) interface.select() calls in modules
This commit is contained in:
parent
70533877ca
commit
c8438dfa66
4 changed files with 16 additions and 4 deletions
|
|
@ -5,6 +5,10 @@
|
|||
dirs = ntop.getDirs()
|
||||
package.path = dirs.installdir .. "/scripts/lua/modules/?.lua;" .. package.path
|
||||
|
||||
-- keep calling this before including modules to avoid that the
|
||||
-- current interface is changed by (unexpected) interface.select() calls
|
||||
local ifstats = interface.getStats()
|
||||
|
||||
require "lua_utils"
|
||||
require "alert_utils"
|
||||
local callback_utils = require "callback_utils"
|
||||
|
|
@ -17,7 +21,6 @@ end
|
|||
-- ########################################################
|
||||
|
||||
local verbose = ntop.verboseTrace()
|
||||
local ifstats = interface.getStats()
|
||||
local _ifname = ifstats.name
|
||||
|
||||
-- ########################################################
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue