When not using OpenSSL from ports, do not try to unmount the chrooted

engines directory.

PR:		201423 (based on)
Submitted by:	girgen
Sponsored by:	Absolight
This commit is contained in:
Mathieu Arnold 2015-08-31 10:06:27 +00:00
parent ba5b16df28
commit 6c84a7b494
Notes: svn2git 2021-03-31 03:12:20 +00:00
svn path=/head/; revision=395660
4 changed files with 10 additions and 10 deletions

View file

@ -8,7 +8,7 @@ PORTVERSION= ${ISCVERSION:S/-P/P/}
PORTREVISION= 0
.else
# dns/bind910 here
PORTREVISION= 1
PORTREVISION= 2
.endif
CATEGORIES= dns net ipv6
MASTER_SITES= ISC/bind9/${ISCVERSION}

View file

@ -232,10 +232,10 @@ named_stop()
named_poststop()
{
if [ -n "${named_chrootdir}" -a -c ${named_chrootdir}/dev/null ]; then
# unmount OpenSSL engines, if they were not mounted but only
# copied, do nothing.
if [ `${SYSCTL_N} security.jail.jailed` -eq 0 -o `${SYSCTL_N} security.jail.mount_allowed` -eq 1 ]; then
umount ${named_chrootdir}${_openssl_engines}
# if using OpenSSL from ports, unmount OpenSSL engines, if they
# were not mounted but only copied, do nothing.
if [ -d ${_openssl_engines} -a \( `${SYSCTL_N} security.jail.jailed` -eq 0 -o `${SYSCTL_N} security.jail.mount_allowed` -eq 1 \) ]; then
umount ${named_chrootdir}${_openssl_engines}
fi
# unmount /dev
if [ `${SYSCTL_N} security.jail.jailed` -eq 0 ]; then

View file

@ -3,7 +3,7 @@
PORTNAME= bind
PORTVERSION= ${ISCVERSION:S/-P/P/}
PORTREVISION= 1
PORTREVISION= 2
CATEGORIES= dns net ipv6
MASTER_SITES= ISC/bind9/${ISCVERSION}
PKGNAMESUFFIX= 99

View file

@ -230,10 +230,10 @@ named_stop()
named_poststop()
{
if [ -n "${named_chrootdir}" -a -c ${named_chrootdir}/dev/null ]; then
# unmount OpenSSL engines, if they were not mounted but only
# copied, do nothing.
if [ `${SYSCTL_N} security.jail.jailed` -eq 0 -o `${SYSCTL_N} security.jail.mount_allowed` -eq 1 ]; then
umount ${named_chrootdir}${_openssl_engines}
# if using OpenSSL from ports, unmount OpenSSL engines, if they
# were not mounted but only copied, do nothing.
if [ -d ${_openssl_engines} -a \( `${SYSCTL_N} security.jail.jailed` -eq 0 -o `${SYSCTL_N} security.jail.mount_allowed` -eq 1 \) ]; then
umount ${named_chrootdir}${_openssl_engines}
fi
# unmount /dev
if [ `${SYSCTL_N} security.jail.jailed` -eq 0 ]; then