Commit 282625fc authored by Martín Ferrari's avatar Martín Ferrari

Solve bug introduced by a change in the output of the 'ip' command.

Patch contributed by Julien Muchembled.
parent b2fddb35
......@@ -434,9 +434,10 @@ def get_addr_data():
raise RuntimeError("Invalid `ip' command output")
idx = int(match.group(1))
name = match.group(2)
if match.group(3):
if name not in bynam:
bynam[name] = byidx[idx] = []
continue # link info
if match.group(3): # BBB: old iproute also shows link info
continue
bynam[name].append(_parse_ip_addr(match.group(4)))
return byidx, bynam
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment