mirror of
https://github.com/ntop/ntopng.git
synced 2026-04-29 23:49:33 +00:00
Store network id as uint16 in alerts
This commit is contained in:
parent
61f74ce0a1
commit
ff576e5967
3 changed files with 6 additions and 5 deletions
|
|
@ -2270,15 +2270,16 @@ end
|
|||
|
||||
function getLocalNetworkAliasById(network)
|
||||
local networks_stats = interface.getNetworksStats()
|
||||
local network_id = tonumber(network)
|
||||
|
||||
-- If network is (u_int8_t)-1 then return an empty value
|
||||
if network == "65535" then
|
||||
if network == nil or network == 65535 then
|
||||
return ' '
|
||||
end
|
||||
|
||||
local label = ''
|
||||
for n, ns in pairs(networks_stats) do
|
||||
if ns.network_id == tonumber(network) then
|
||||
if ns.network_id == network_id then
|
||||
label = getFullLocalNetworkName(ns.network_key)
|
||||
end
|
||||
end
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue