summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlin Năstac <mrness@gentoo.org>2009-03-05 19:31:13 +0000
committerAlin Năstac <mrness@gentoo.org>2009-03-05 19:31:13 +0000
commit635378babf01c8d1aca62f1206fbb98628edf9fa (patch)
tree6087c10792da2f109ed805738e682833b2b0d4d7 /net-proxy/dante/files
parentVersion bump (diff)
downloadgentoo-2-635378babf01c8d1aca62f1206fbb98628edf9fa.tar.gz
gentoo-2-635378babf01c8d1aca62f1206fbb98628edf9fa.tar.bz2
gentoo-2-635378babf01c8d1aca62f1206fbb98628edf9fa.zip
Second try to fix bashisms in dante-sockd script (#260151).
(Portage version: 2.1.6.7/cvs/Linux x86_64)
Diffstat (limited to 'net-proxy/dante/files')
-rw-r--r--net-proxy/dante/files/dante-sockd-init12
1 files changed, 6 insertions, 6 deletions
diff --git a/net-proxy/dante/files/dante-sockd-init b/net-proxy/dante/files/dante-sockd-init
index 336432f938fe..66d02bd6fb2c 100644
--- a/net-proxy/dante/files/dante-sockd-init
+++ b/net-proxy/dante/files/dante-sockd-init
@@ -1,7 +1,7 @@
#!/sbin/runscript
# Copyright 1999-2004 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/net-proxy/dante/files/dante-sockd-init,v 1.5 2009/02/28 09:53:42 mrness Exp $
+# $Header: /var/cvsroot/gentoo-x86/net-proxy/dante/files/dante-sockd-init,v 1.6 2009/03/05 19:31:13 mrness Exp $
SOCKD_OPT="-D"
[ "${SOCKD_FORKDEPTH:-1}" -gt 1 ] && SOCKD_OPT="${SOCKD_OPT} -N ${SOCKD_FORKDEPTH}"
@@ -21,8 +21,8 @@ checkconfig() {
eerror "for more info, see: man sockd.conf"
return 1
fi
-
- /usr/sbin/sockd -V 2>&1 >/tmp/dante-sockd.checkconf
+
+ /usr/sbin/sockd -V >/tmp/dante-sockd.checkconf 2>&1
if [ $? -ne 0 ]; then
cat /tmp/dante-sockd.checkconf
eerror "Something is wrong with your configuration file"
@@ -30,13 +30,13 @@ checkconfig() {
return 1
fi
rm /tmp/dante-sockd.checkconf
-
+
#Create pidfile with owner set to daemon's uid
DAEMON_UID=`sed -e '/^[ \t]*user[.]notprivileged[ \t]*:/{s/.*:[ \t]*//;q};d' /etc/socks/sockd.conf`
if [ -n "$DAEMON_UID" ]; then
touch $PIDFILE && chown $DAEMON_UID $PIDFILE
fi
-
+
return 0
}
@@ -44,7 +44,7 @@ start() {
checkconfig || return 1
ebegin "Starting dante sockd"
start-stop-daemon --start --quiet --pidfile $PIDFILE \
- --make-pidfile --exec /usr/sbin/sockd -- ${SOCKD_OPT} 2>&1 >/dev/null
+ --make-pidfile --exec /usr/sbin/sockd -- ${SOCKD_OPT} >/dev/null 2>&1
eend $? "Failed to start sockd"
}