First code cleanup for better memory management

This commit is contained in:
Matteo Biscosi 2024-02-14 16:12:28 +00:00
parent b5a4c2621b
commit 2f76c9bf4b
21 changed files with 968 additions and 852 deletions

View file

@ -5,8 +5,18 @@
dirs = ntop.getDirs()
package.path = dirs.installdir .. "/scripts/lua/modules/?.lua;" .. package.path
-- Hack to avoid include loops
if (pragma_once_callback_utils == true) then
tprint(debug.traceback())
-- avoid multiple inclusions
return
end
pragma_once_callback_utils = true
local os_utils = require "os_utils"
local callback_utils = {}
local clock_start = os.clock()