summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCédric Krier <cedk@gentoo.org>2008-11-01 15:50:06 +0000
committerCédric Krier <cedk@gentoo.org>2008-11-01 15:50:06 +0000
commitf31462f90ded5e011f4c1aeb0e5dd725b756698d (patch)
tree5cf43c65bce02f0a7b439da7f050124c1c7bdd62 /net-misc/openvpn/files
parentAdd dependency to pkgconfig for bug #244606 (diff)
downloadhistorical-f31462f90ded5e011f4c1aeb0e5dd725b756698d.tar.gz
historical-f31462f90ded5e011f4c1aeb0e5dd725b756698d.tar.bz2
historical-f31462f90ded5e011f4c1aeb0e5dd725b756698d.zip
Fix init script for bug #234667
Package-Manager: portage-2.1.4.5
Diffstat (limited to 'net-misc/openvpn/files')
-rwxr-xr-xnet-misc/openvpn/files/openvpn-2.1.init5
1 files changed, 3 insertions, 2 deletions
diff --git a/net-misc/openvpn/files/openvpn-2.1.init b/net-misc/openvpn/files/openvpn-2.1.init
index daa163582173..ae8d5980fc07 100755
--- a/net-misc/openvpn/files/openvpn-2.1.init
+++ b/net-misc/openvpn/files/openvpn-2.1.init
@@ -107,11 +107,12 @@ start() {
fi
# Ensure that our scripts get the PEER_DNS variable
- export PEER_DNS
+ [ -n "${PEER_DNS}" ] && args="${args} --setenv PEER_DNS ${PEER_DNS}"
[ "${reenter}" = "yes" ] && mark_service_inactive "${SVCNAME}"
start-stop-daemon --start --exec /usr/sbin/openvpn --pidfile "${VPNPID}" \
- -- --config "${VPNCONF}" --writepid "${VPNPID}" --daemon ${args}
+ -- --config "${VPNCONF}" --writepid "${VPNPID}" --daemon \
+ --setenv SVCNAME "${SVCNAME}" ${args}
eend $? "Check your logs to see why startup failed"
}