Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 01 Oct 2014 18:30:35 -0700
From:      Colin Percival <cperciva@freebsd.org>
To:        Hiroki Sato <hrs@FreeBSD.org>, src-committers@freebsd.org,  svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   Re: svn commit: r272393 - head/etc
Message-ID:  <542CAABB.5090900@freebsd.org>
In-Reply-To: <201410020116.s921GVTZ033933@svn.freebsd.org>
References:  <201410020116.s921GVTZ033933@svn.freebsd.org>

next in thread | previous in thread | raw e-mail | index | archive | help
On 10/01/14 18:16, Hiroki Sato wrote:
>   This is an attempt to solve a problem that rc.d scripts from third-party
>   software do not have entries in /etc/defaults/rc.conf.

Isn't this why we have the
> : ${foo_enable="NO"}
idiom in ports rc.d files?

>   The fact that
>   load_rc_config() reads rc.conf only once and /etc/rc invokes the function
>   before running rc.d scripts made developers confused for a long time because
>   load_rc_config() just before run_rc_command() in each rc.d script overrides
>   variables only when the script is directly invoked, not from /etc/rc.

If a script is setting variables for its own use, there's no need to use
functions from rc.subr -- it can just set the variables directly.  If a
script is editing rc.conf, sending a SIGALRM to $$ will signal /etc/rc to
re-source rc.conf.

I'm really not clear on what this commit accomplishes.

-- 
Colin Percival
Security Officer Emeritus, FreeBSD | The power to serve
Founder, Tarsnap | www.tarsnap.com | Online backups for the truly paranoid




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?542CAABB.5090900>