Improve bridge preferences with netfilter interfaces

This commit is contained in:
Emanuele Faranda 2017-11-22 17:46:51 +01:00
parent 2c2374bfbc
commit 7fbcd40ec5
2 changed files with 9 additions and 2 deletions

View file

@ -3365,7 +3365,7 @@ function isBridgeInterface(ifstats)
return ifstats.inline
end
function hasBridgeInterfaces()
function hasBridgeInterfaces(skip_netfilter)
local curif = ifname
local ifnames = interface.getIfNames()
local found = false
@ -3374,7 +3374,8 @@ function hasBridgeInterfaces()
interface.select(ifname)
local ifstats = interface.getStats()
if isBridgeInterface(ifstats) then
if isBridgeInterface(ifstats)
and (skip_netfilter~=true or ifstats.type ~= "netfilter") then
found = true
break
end