Fix use after free and regen dhcpd.conf