Date: Thu, 29 Jun 2000 23:48:16 -0400 (EDT)
From: adrian@ubergeeks.com
To: FreeBSD-gnats-submit@freebsd.org
Subject: bin/19592: pccard_ether does not honor dhcp_{program,flags} settings in rc.conf
Message-ID: <200006300348.XAA05206@lorax.ubergeeks.com>
next in thread | raw e-mail | index | archive | help
>Number: 19592
>Category: bin
>Synopsis: pccard_ether does not honor dhcp_{program,flags} from rc.conf
>Confidential: no
>Severity: non-critical
>Priority: medium
>Responsible: freebsd-bugs
>State: open
>Quarter:
>Keywords:
>Date-Required:
>Class: sw-bug
>Submitter-Id: current-users
>Arrival-Date: Thu Jun 29 20:50:01 PDT 2000
>Closed-Date:
>Last-Modified:
>Originator: Adrian Filipi-Martin
>Release: FreeBSD 4.0-STABLE i386
>Organization:
Ubergeeks Consulting
>Environment:
4-stable from 06/29/00.
>Description:
If you set either of the dhcp_program or dhcp_flags variables to
non-default values in /etc/rc.conf _AND_ use DHCP with a PCCARD device,
your settings will not be used.
>How-To-Repeat:
Set either dhcp_program or dhcp_flags in /etc/rc.conf, e.g.
dhcp_flags="-D", and then insert your pccard network device.
The changes will not be used. In contrast the settings are
used in rc.network.
>Fix:
Apply the included patch. Note it also adds some unnecessary {}'s for
the sake of stylistic consistency lower down in the script.
--- pccard_ether.orig Thu Jun 29 19:00:37 2000
+++ pccard_ether Thu Jun 29 23:31:34 2000
@@ -23,18 +23,18 @@
[Nn][Oo] | '')
;;
[Dd][Hh][Cc][Pp])
- if [ -r /sbin/dhclient ]; then
+ if [ -r ${dhcp_program:=/sbin/dhclient} ]; then
if [ -s /var/run/dhclient.pid ]; then
kill `cat /var/run/dhclient.pid`
rm /var/run/dhclient.pid
fi
- /sbin/dhclient $interface
+ ${dhcp_program} ${dhcp_flags} ${interface}
elif [ -r /usr/local/sbin/dhcpc ]; then
if [ -s /var/run/dhcpc.pid ]; then
kill `cat /var/run/dhcpc.pid`
rm /var/run/dhcpc.pid
fi
- /usr/local/sbin/dhcpc $interface $*
+ /usr/local/sbin/dhcpc ${interface} $*
else
echo "DHCP client software not available (isc-dhcp2)"
fi
>Release-Note:
>Audit-Trail:
>Unformatted:
To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-bugs" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200006300348.XAA05206>
