Skip to content

Commit

Permalink
IsBridgeable: cleanup
Browse files Browse the repository at this point in the history
  • Loading branch information
mchf committed Jun 20, 2014
1 parent c199c1c commit 0b732d1
Showing 1 changed file with 8 additions and 17 deletions.
25 changes: 8 additions & 17 deletions src/modules/LanItems.rb
Original file line number Diff line number Diff line change
Expand Up @@ -823,10 +823,8 @@ def IsBridgeable(bridgeMaster, itemId)
devname = GetDeviceName(itemId)
bonded = BuildBondIndex()

if bonded[ devname]
Builtins.y2debug(
"IsBridgeable: excluding lan item (#{itemId}: #{devname}) - is bonded",
)
if bonded[devname]
log.debug("Excluding lan item (#{itemId}: #{devname}) - is bonded")
return false
end

Expand All @@ -835,28 +833,21 @@ def IsBridgeable(bridgeMaster, itemId)
# exclude forbidden configurations
case devtype
when "br"
Builtins.y2debug(
"IsBridgeable: excluding lan item (#{itemId}: #{devname}) - is bridge",
)
log.debug("Excluding lan item (#{itemId}: #{devname}) - is bridge")
return false

when "tun"
Builtins.y2debug(
"IsBridgeable: excluding lan item (#{itemId}: #{devname}) - is tun",
)
log.debug("Excluding lan item (#{itemId}: #{devname}) - is tun")
return false
end

case ifcfg[ "STARTMODE"]
case ifcfg["STARTMODE"]
when "nfsroot"
Builtins.y2debug(
"IsBridgeable: excluding lan item (#{itemId}: #{devname}) - is nfsroot",
)
log.debug("Excluding lan item (#{itemId}: #{devname}) - is nfsroot")
return false

when "ifplugd"
Builtins.y2debug(
"IsBridgeable: excluding lan item (#{itemId}: #{devname}) - ifplugd",
)
log.debug("Excluding lan item (#{itemId}: #{devname}) - ifplugd")
return false

else
Expand Down

0 comments on commit 0b732d1

Please sign in to comment.