Date: Tue, 22 Nov 2005 17:08:27 +0300 From: Yar Tikhiy <yar@comp.chem.msu.su> To: Maksim Yevmenkin <maksim.yevmenkin@gmail.com> Cc: cvs-src@freebsd.org, src-committers@freebsd.org, cvs-all@freebsd.org Subject: Re: cvs commit: src/etc/rc.d hcsecd sdpd Message-ID: <20051122140827.GB91654@comp.chem.msu.su> In-Reply-To: <bb4a86c70511181003y5a8d404bnf4cb0a68c6d4ed24@mail.gmail.com> References: <200511152036.jAFKaQMZ089811@repoman.freebsd.org> <20051118101729.GA87399@freefall.freebsd.org> <bb4a86c70511181003y5a8d404bnf4cb0a68c6d4ed24@mail.gmail.com>
next in thread | previous in thread | raw e-mail | index | archive | help
On Fri, Nov 18, 2005 at 10:03:04AM -0800, Maksim Yevmenkin wrote:
>
> > > emax 2005-11-15 20:36:26 UTC
> > >
> > > FreeBSD src repository
> > >
> > > Modified files:
> > > etc/rc.d hcsecd sdpd
> > > Log:
> > > Revise hcsecd(8) and sdpd(8) rc.d scripts.
> > >
> > > - Have both scripts automatically kldload ng_btsocket(4). I did not want to
> > > do it, but its easier for users and it seems other scripts do similar things;
> >
> > You need not override the start method for such a hack.
> > Just put the kldload in the prestart method.
>
> actually, i had to. i have defined sdpd_group and sdpd_user variables,
> and, by default, run_rc_command() checks if ${name}_group and
> ${name}_user are defined and uses su(1) to start ${command}.
>
> i guess, i could have used prestart and undefine sdpd_group and
> sdpd_user before calling run_rc_command().
I guess different variable names should have been used.
Choosing magic names first and fighting their side-effects
then doesn't look good to me.
> > In addition, you could check if the module is loaded already.
> > See the pf* scripts for an example.
>
> well, yes, i could. but a saw a couple of bad examples in /etc/rc.d :)
> that do it without checking. if it really bugs people, i could fix
> this.
It's almost never too late to fix slips in our computer programs,
unlike in some other areas of life ;-)
--
Yar
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20051122140827.GB91654>
