mirror of
https://github.com/ntop/ntopng.git
synced 2026-04-29 23:49:33 +00:00
Remove json from hosts checkpoint and fix host iterator bug
This commit is contained in:
parent
5b9bba1188
commit
d350a3131f
9 changed files with 89 additions and 23 deletions
|
|
@ -47,18 +47,18 @@ local function getBatchedIterator(batched_function, field, function_params)
|
|||
function_params = function_params or {}
|
||||
|
||||
return function()
|
||||
if ((nextSlot == 0) or (nextSlot == nil)) and not first_iteration then
|
||||
iterator_finished = true
|
||||
end
|
||||
|
||||
if iterator_finished then return nil end
|
||||
|
||||
if (loaded_elems == nil) or table.empty(loaded_elems) then
|
||||
if loaded_elems ~= nil then
|
||||
-- that was the first iteration
|
||||
first_iteration = false
|
||||
end
|
||||
|
||||
if ((nextSlot == 0) or (nextSlot == nil)) and not first_iteration then
|
||||
iterator_finished = true
|
||||
end
|
||||
|
||||
if iterator_finished then return nil end
|
||||
|
||||
-- we need to load new slots from C
|
||||
if(debug_enabled) then
|
||||
io.write("getBatchedIterator["..field.."](curSlot=".. nextSlot ..")\n")
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue