Use the checkyesno routine instead of a case statement to
check an rc.conf(5) variable. This is in line with rc.d style.
This commit is contained in:
parent
e27b3ff8b6
commit
82e3bcc0d5
@ -27,17 +27,15 @@ mountd_precmd()
|
||||
|
||||
# mountd flags will differ depending on rc.conf settings
|
||||
#
|
||||
case ${nfs_server_enable} in
|
||||
[Yy][Ee][Ss])
|
||||
if checkyesno nfs_server_enable ; then
|
||||
if checkyesno weak_mountd_authentication; then
|
||||
mountd_flags="${mountd_flags} -n"
|
||||
fi
|
||||
;;
|
||||
*)
|
||||
else
|
||||
if checkyesno mountd_enable; then
|
||||
checkyesno weak_mountd_authentication && mountd_flags="-n"
|
||||
fi
|
||||
esac
|
||||
fi
|
||||
rm -f /var/db/mountdtab
|
||||
( umask 022 ; > /var/db/mountdtab )
|
||||
return 0
|
||||
|
Loading…
Reference in New Issue
Block a user