Commit fd87fef6 authored by martin's avatar martin

Compat with braindead ubuntu changes

parent a059a46d
......@@ -292,7 +292,7 @@ def get_if_data():
match = re.search(r'^(\d+):\s+(.*)', line)
idx = int(match.group(1))
match = re.search(r'^(\d+): (\S+): <(\S+)> mtu (\d+) qdisc \S+' +
r'.*link/\S+ ([0-9a-f:]+) brd ([0-9a-f:]+)', line)
r'.*link/\S+(?: ([0-9a-f:]+) brd ([0-9a-f:]+))?', line)
flags = match.group(3).split(",")
i = interface(
index = match.group(1),
......
......@@ -27,7 +27,7 @@ def process_ipcmd(str):
continue
# Assume cur is defined
assert cur != None
match = re.search(r'^\s+link/\S* ([0-9a-f:]+)(?: |$)', line)
match = re.search(r'^\s+link/\S*(?: ([0-9a-f:]+))?(?: |$)', line)
if match != None:
out[cur]['lladdr'] = match.group(1)
continue
......@@ -49,7 +49,7 @@ def process_ipcmd(str):
'family': 'inet6'})
continue
match = re.search(r'^\s{6}', line)
match = re.search(r'^\s{4}', line)
assert match != None
return out
......
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