rc.subr: Allow rc.conf.d with multi-directory local_startup.
I also changed ${...%*/rc.d} to ${...%/rc.d} since the shortest match always has an empty string for the asterisk. PR: 201641 Submitted by: Jamie Landeg-Jones (original version) MFC after: 1 week
This commit is contained in:
parent
577c341353
commit
738b6d4109
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=286163
@ -1333,7 +1333,8 @@ load_rc_config()
|
||||
# If a service name was specified, attempt to load
|
||||
# service-specific configuration
|
||||
if [ -n "$_name" ] ; then
|
||||
for _d in /etc ${local_startup%*/rc.d}; do
|
||||
for _d in /etc ${local_startup}; do
|
||||
_d=${_d%/rc.d}
|
||||
if [ -f ${_d}/rc.conf.d/"$_name" ]; then
|
||||
debug "Sourcing ${_d}/rc.conf.d/$_name"
|
||||
. ${_d}/rc.conf.d/"$_name"
|
||||
|
Loading…
Reference in New Issue
Block a user