Making use of set_rcvar.

Hiroki Sato hrs at FreeBSD.org
Sat Jan 7 23:12:32 UTC 2012


Doug Barton <dougb at freebsd.org> wrote
  in <4F08C95F.6040808 at FreeBSD.org>:

do> On 01/07/2012 03:25, Pawel Jakub Dawidek wrote:
do> > On Fri, Jan 06, 2012 at 05:05:58PM -0800, Doug Barton wrote:
do> >> On 01/06/2012 06:13, Pawel Jakub Dawidek wrote:
do> >>> Any objections?
do> >>>
do> >>> 	http://people.freebsd.org/~pjd/patches/set_rcvar.patch
do> >>>
do> >>> This patch only changes scripts where set_rcvar can be used with no
do> >>> arguments.
do> >>
do> >> Please don't do this.
do> >>
do> >> Jilles already pointed out the important reason, it adds pointless
do> >> forks. I suggested a long time ago that we remove set_rcvar altogether
do> >> but I got a lot of resistance to it, and never pursued it. Perhaps it's
do> >> time to revisit that.
do> >
do> > It is a total mess now then and it is definiately not intuitive when
do> > there are much more bad examples than good ones:
do>
do> I agree, which is why I previously proposed assigning them all directly
do> when possible (which is in almost all cases). If no one speaks up
do> opposing this idea in the next few days I'm still prepared to proceed.

 I am always wondering if defining $rcvar as "${name}_enable" at the
 end of load_rc_config() when $rcvar is undefined is bad idea.

 Is there any problem with removing rcvar=... in individual rc.d
 scripts except for non-standard ones (empty or different from
 ${name}_enable)?  It looks simpler than writing the same line
 "rcvar=${name}_enable" many times in various places.

-- Hiroki
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 196 bytes
Desc: not available
Url : http://lists.freebsd.org/pipermail/freebsd-rc/attachments/20120107/e71d29b6/attachment.pgp


More information about the freebsd-rc mailing list