summaryrefslogtreecommitdiffstats
path: root/usr.sbin
diff options
context:
space:
mode:
authordelphij <delphij@FreeBSD.org>2006-02-06 06:49:57 +0000
committerdelphij <delphij@FreeBSD.org>2006-02-06 06:49:57 +0000
commitfd420369b1970d74d4f71a71cd53140f5dc5c528 (patch)
tree70c9499f11088e5e2dd224030d324b9738a40504 /usr.sbin
parent0fdc8d7b7221f0a885507e06716a1e61419a4b35 (diff)
downloadFreeBSD-src-fd420369b1970d74d4f71a71cd53140f5dc5c528.zip
FreeBSD-src-fd420369b1970d74d4f71a71cd53140f5dc5c528.tar.gz
Attempt to fix DHCP address acquisition which was broken by rev. 1.133.
MFC After: 3 days
Diffstat (limited to 'usr.sbin')
-rw-r--r--usr.sbin/sysinstall/tcpip.c9
1 files changed, 6 insertions, 3 deletions
diff --git a/usr.sbin/sysinstall/tcpip.c b/usr.sbin/sysinstall/tcpip.c
index 10c9c2c..6c21226 100644
--- a/usr.sbin/sysinstall/tcpip.c
+++ b/usr.sbin/sysinstall/tcpip.c
@@ -596,9 +596,12 @@ netconfig:
ipv4_enable = TRUE;
if (ipv4_enable) {
sprintf(ifn, "%s%s", VAR_IFCONFIG, devp->name);
- if (use_dhcp)
- sprintf(temp, "DHCP %s", extras);
- else
+ if (use_dhcp) {
+ if (strlen(extras) > 0)
+ sprintf(temp, "DHCP %s", extras);
+ else
+ sprintf(temp, "DHCP");
+ } else
sprintf(temp, "inet %s %s netmask %s",
ipaddr, extras, netmask);
variable_set2(ifn, temp, 1);
OpenPOWER on IntegriCloud