When a network device is specified to tcpip_tx() or it's children, treat

it as a fallback network device rather than an explicitly forced network
device.

Clear routing table entries before re-attempting DHCP.
This commit is contained in:
Michael Brown
2007-01-16 04:09:13 +00:00
parent 1a1fc23417
commit f11da20f25
4 changed files with 7 additions and 4 deletions

View File

@@ -58,6 +58,9 @@ int dhcp ( struct net_device *netdev ) {
dhcp_options = NULL;
}
/* Clear any existing routing table entry */
del_ipv4_address ( netdev );
/* Issue DHCP request */
printf ( "DHCP (%s %s)...", netdev->name, netdev_hwaddr ( netdev ) );
memset ( &dhcp, 0, sizeof ( dhcp ) );