Date: Fri, 10 Feb 2006 19:46:08 +0100 (CET) From: Ulf Lilleengen <lulf@stud.ntnu.no> To: FreeBSD-gnats-submit@FreeBSD.org Subject: bin/93145: [PATCH] 6.1-BETA1 DHCP config error Message-ID: <20060210184608.E261722887@studby.ntnu.no> Resent-Message-ID: <200602101850.k1AIo3d9010150@freefall.freebsd.org>
next in thread | raw e-mail | index | archive | help
>Number: 93145
>Category: bin
>Synopsis: [PATCH] 6.1-BETA1 DHCP config error
>Confidential: no
>Severity: serious
>Priority: medium
>Responsible: freebsd-bugs
>State: open
>Quarter:
>Keywords:
>Date-Required:
>Class: sw-bug
>Submitter-Id: current-users
>Arrival-Date: Fri Feb 10 18:50:02 GMT 2006
>Closed-Date:
>Last-Modified:
>Originator: Ulf Lilleengen
>Release: FreeBSD 7.0-CURRENT i386
>Organization:
>Environment:
System: FreeBSD vimes.studby.ntnu.no 7.0-CURRENT FreeBSD 7.0-CURRENT #4: Wed Jan 25 21:16:02 CET 2006 root@vimes.studby.ntnu.no:/usr/obj/usr/src/sys/VIMES i386
>Description:
When i try to install 6.1-BETA1 and choose to use DHCP to configure my
rl0 interface, i get an error saying "ifconfig: DHCP: bad value" coming
from the installer trying to run ifconfig rl0 DHCP.
I looked at the code in network.c in sysinstall, and found a difference
between CURRENT and BETA1, which was an strstr check being changed.
Patch added below.
>How-To-Repeat:
Try install 6.1-BETA1 and configure network interface with DHCP
>Fix:
--- sysinstall_dhcpconfig.diff begins here ---
Index: network.c
===================================================================
RCS file: /home/cvs/ncvs/src/usr.sbin/sysinstall/network.c,v
retrieving revision 1.51
diff -u -r1.51 network.c
--- network.c 1 Nov 2002 02:05:05 -0000 1.51
+++ network.c 10 Feb 2006 18:37:24 -0000
@@ -126,7 +126,7 @@
snprintf(ifconfig, 255, "%s%s", VAR_IFCONFIG, dev->name);
cp = variable_get(ifconfig);
if (cp) {
- if (strcmp(cp, "DHCP")) {
+ if (strcmp(cp, "DHCP") == NULL) {
msgDebug("ifconfig %s %s\n", dev->name, cp);
i = vsystem("ifconfig %s %s", dev->name, cp);
if (i) {
--- sysinstall_dhcpconfig.diff ends here ---
>Release-Note:
>Audit-Trail:
>Unformatted:
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20060210184608.E261722887>
