Fixes bug in obaining DHCP server address

Adds a checks to makes sure the DHCP server address exists.