avoid possible errors with new broadcast handling in linux
parent
cb2cfaebda
commit
08e6c1d82b
|
@ -1877,9 +1877,11 @@ class LinuxNetwork(Network):
|
||||||
if not line:
|
if not line:
|
||||||
continue
|
continue
|
||||||
words = line.split()
|
words = line.split()
|
||||||
|
broadcast = ''
|
||||||
if words[0] == 'inet':
|
if words[0] == 'inet':
|
||||||
if '/' in words[1]:
|
if '/' in words[1]:
|
||||||
address, netmask_length = words[1].split('/')
|
address, netmask_length = words[1].split('/')
|
||||||
|
if len(words) > 3:
|
||||||
broadcast = words[3]
|
broadcast = words[3]
|
||||||
else:
|
else:
|
||||||
# pointopoint interfaces do not have a prefix
|
# pointopoint interfaces do not have a prefix
|
||||||
|
|
Loading…
Reference in New Issue