Description
In minigraph.py:
if vintf.find(str(QName(ns, "DhcpRelays"))) is not None:
vintfdhcpservers = vintf.find(str(QName(ns, "DhcpRelays"))).text
vdhcpserver_list = vintfdhcpservers.split(';')
vlan_attributes['dhcp_servers'] = vdhcpserver_list
This will crash upon case of <DhcpRelays></DhcpRelays>, i.e. vintf.find(str(QName(ns, "DhcpRelays"))) is not None but vintf.find(str(QName(ns, "DhcpRelays"))).text is None.
Steps to reproduce the issue:
Create a minigraph with <DhcpRelays></DhcpRelays> in <VlanInterface> section, then sonic-cfggen -m.
Description
In minigraph.py:
This will crash upon case of
<DhcpRelays></DhcpRelays>, i.e.vintf.find(str(QName(ns, "DhcpRelays"))) is not Nonebutvintf.find(str(QName(ns, "DhcpRelays"))).text is None.Steps to reproduce the issue:
Create a minigraph with
<DhcpRelays></DhcpRelays>in<VlanInterface>section, thensonic-cfggen -m.