projects
/
privoxy.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
If the provided URL isn't valid, don't show the
[privoxy.git]
/
slackware
/
rc.privoxy.orig
diff --git
a/slackware/rc.privoxy.orig
b/slackware/rc.privoxy.orig
index
632a6b7
..
cbd0db5
100644
(file)
--- a/
slackware/rc.privoxy.orig
+++ b/
slackware/rc.privoxy.orig
@@
-1,5
+1,9
@@
#!/bin/sh
# ********************************************************************
#!/bin/sh
# ********************************************************************
+# This script uses exit to return proper error codes,
+# sourcing (. /path/to/rc.privoxy) it in your system's
+# rc files is a bad idea.
+# ********************************************************************
RETVAL=1
RETVAL=1
@@
-8,7
+12,7
@@
PRIVOXY_BIN="%SBIN_DEST%/$PRIVOXY_PRG"
PRIVOXY_CONF="%CONF_DEST%/config"
PRIVOXY_USER="%USER%"
PRIVOXY_GROUP="%GROUP%"
PRIVOXY_CONF="%CONF_DEST%/config"
PRIVOXY_USER="%USER%"
PRIVOXY_GROUP="%GROUP%"
-PRIVOXY_PID="/var/run/$PRIVOXY_PRG
"/$PRIVOXY_PRG.pid
+PRIVOXY_PID="/var/run/$PRIVOXY_PRG
.pid"
declare -i check
check=(`/bin/ps -e|/bin/grep $PRIVOXY_PRG|/usr/bin/wc -l`)
declare -i check
check=(`/bin/ps -e|/bin/grep $PRIVOXY_PRG|/usr/bin/wc -l`)
@@
-19,14
+23,14
@@
if [ ! -f $PRIVOXY_CONF ] ; then exit 0 ;fi
# See how we were called.
# See how we were called.
-PRIVOXY="$PRIVOXY_BIN $PRIVOXY_CONF"
+PRIVOXY="$PRIVOXY_BIN
--user $PRIVOXY_USER.$PRIVOXY_GROUP --pidfile $PRIVOXY_PID
$PRIVOXY_CONF"
start () {
# start daemon
echo -n $"Starting $PRIVOXY_PRG: "
if [ ! -f $PRIVOXY_PID ]; then
start () {
# start daemon
echo -n $"Starting $PRIVOXY_PRG: "
if [ ! -f $PRIVOXY_PID ]; then
- (
$PRIVOXY --user $PRIVOXY_USER.$PRIVOXY_GROUP --pidfile $PRIVOXY_PID
2>/dev/tty9 ) \
+ (
$PRIVOXY
2>/dev/tty9 ) \
&& echo " OK" \
&& /bin/touch /var/lock/$PRIVOXY_PRG \
&& RETVAL=0
&& echo " OK" \
&& /bin/touch /var/lock/$PRIVOXY_PRG \
&& RETVAL=0