cvs commit: src/etc network.subr
Mike Telahun Makonnen
mmakonnen at gmail.com
Thu Mar 29 20:57:48 UTC 2007
On 3/29/07, Andrey Chernov <ache at freebsd.org> wrote:
> On Thu, Mar 29, 2007 at 03:34:45PM -0400, John Baldwin wrote:
> > The change in v1.28 fixed a similar warning where you'd get something like
> > /etc/rc.d/dhclient: WARNING: $background_dhclient_bge0 is not set properly
> > (where bge0 is an interface name). 1.28 fixed the warning for me, but I don't
> > use background_dhclient and have none of the variables set. Maybe Andrey is
> > seeing a warning in the non-default case when a variable is set?
> I have plain DHCP and don't use background_dhclient too. I wonder why
> somebody have not see it. Look at this lines from v1.28:
Yeah apologies, you're right, it's not the same bug. However, the fix
is still wrong.
The correct fix is to put the sample fxp line a comment.
The reason your fix is wrong is because get_if_var() is supposed to
give the default value only if the variable it's looking for is unset.
If it is set it is supposed to give you whatever value it's set to. In
the fxp0 case, it is erroneously set to null (i.e ""), so checkyesno()
correctly complains that it is set to an improper value (which it is).
So, what you should do is back your fix out and comment out the fxp0
line in /etc/defaults/rc.conf.
More information about the cvs-src