diff --git a/net-vpn/tor/files/tor.initd-r9 b/net-vpn/tor/files/tor.initd-r9 index c1639c2af95a..8f9ed82b42eb 100644 --- a/net-vpn/tor/files/tor.initd-r9 +++ b/net-vpn/tor/files/tor.initd-r9 @@ -3,8 +3,8 @@ # Distributed under the terms of the GNU General Public License v2 command=/usr/bin/tor -pidfile=/run/tor/tor.pid -command_args="--hush --runasdaemon 1 --pidfile \"${pidfile}\"" +pidfile=/run/tor/${RC_SVCNAME}.pid +command_args="--hush -f ${torrc} --runasdaemon 1 --pidfile \"${pidfile}\"" retry=${GRACEFUL_TIMEOUT:-60} stopsig=INT command_progress=yes @@ -16,9 +16,9 @@ description_checkconfig="Check for valid config file" description_reload="Reload the configuration" checkconfig() { - ${command} --verify-config --hush > /dev/null 2>&1 + ${command} --verify-config --hush -f ${torrc} > /dev/null 2>&1 if [ $? -ne 0 ] ; then - eerror "Tor configuration (/etc/tor/torrc) is not valid." + eerror "Tor configuration (${torrc}) is not valid." eerror "Example is in /etc/tor/torrc.sample" return 1 fi