Merge pull request #348 from coreemu/bugfix/existing-bridges
updates to cases when checking existing bridges using ip -j returns a…
This commit is contained in:
commit
80c06f8216
1 changed files with 3 additions and 1 deletions
|
@ -268,7 +268,9 @@ class LinuxNetClient:
|
|||
output = self.run(f"{IP_BIN} -j link show type bridge")
|
||||
bridges = json.loads(output)
|
||||
for bridge in bridges:
|
||||
name = bridge["ifname"]
|
||||
name = bridge.get("ifname")
|
||||
if not name:
|
||||
continue
|
||||
fields = name.split(".")
|
||||
if len(fields) != 3:
|
||||
continue
|
||||
|
|
Loading…
Reference in a new issue