mirror of
https://github.com/kernelkit/infix.git
synced 2026-07-31 04:53:01 +02:00
yanger: DHCP: Fix bug when search exist but no nameserver
When running a DHCP test `resolvconf -l` looked like this: admin@client:~$ resolvconf -l search example.com # e5 admin@client:~$ This resulted in broken result when reading operational data from system-state (which used resolvonf -l)
This commit is contained in:
@@ -115,7 +115,8 @@ def add_dns(out):
|
||||
continue
|
||||
|
||||
elif line.startswith('search'):
|
||||
search.extend(line.split()[1:])
|
||||
parts = line.split('#', 1)
|
||||
search.extend(parts[0].split()[1:])
|
||||
|
||||
insert(out, "infix-system:dns-resolver", "options", options)
|
||||
insert(out, "infix-system:dns-resolver", "server", servers)
|
||||
|
||||
Reference in New Issue
Block a user