summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorManuel Reimer <manuel.reimer@gmx.de>2013-10-02 17:24:31 +0200
committerManuel Reimer <manuel.reimer@gmx.de>2013-10-02 17:24:31 +0200
commitd418509cdcf53a2ac5ad06f8bf88a61fd9c2dca0 (patch)
treeb1adfb2e3695db5f6ff4f501953b9c9b572b442f
parent9a065330215cedfe18bd47aad03fcaab148daac7 (diff)
downloadrunvdr-extreme-d418509cdcf53a2ac5ad06f8bf88a61fd9c2dca0.tar.gz
runvdr-extreme-d418509cdcf53a2ac5ad06f8bf88a61fd9c2dca0.tar.bz2
Replaced "closed outputs" with "redirect to /dev/null"
* Fixes problem with "ps" which no longer accepts closed STDOUT in newer versions
-rwxr-xr-xrunvdr14
1 files changed, 7 insertions, 7 deletions
diff --git a/runvdr b/runvdr
index 7ca0e92..1657d9e 100755
--- a/runvdr
+++ b/runvdr
@@ -632,10 +632,10 @@ function WaitKill() {
GetChilds "$1" "$2"
echo -n "Sending ${#childlist[*]} processes the TERM signal."
- $KILL -TERM ${childlist[*]} >&- 2>&-
+ $KILL -TERM ${childlist[*]} 2>/dev/null
for ((i=0;i<$3;i++)) ; do
- $PS ${childlist[*]} >&- 2>&- || { echo terminated. ; return ; }
+ $PS ${childlist[*]} >/dev/null || { echo terminated. ; return ; }
echo -n .
$SLEEP 1
@@ -643,10 +643,10 @@ function WaitKill() {
echo
echo -n "Sending ${#childlist[*]} processes the KILL signal."
- $KILL -KILL ${childlist[*]} >&- 2>&-
+ $KILL -KILL ${childlist[*]} 2>/dev/null
for ((i=0;i<$4;i++)) ; do
- $PS ${childlist[*]} >&- 2>&- || { echo terminated. ; return ; }
+ $PS ${childlist[*]} >/dev/null || { echo terminated. ; return ; }
echo -n .
$SLEEP 1
done
@@ -749,7 +749,7 @@ if [ "$TERMINATE" != "0" ] ; then
echo -n "Terminating runvdr (PID=$TERMINATE)"
$KILL -TERM $TERMINATE
while [ -z "$WAIT" ] || [ "$WAIT" -gt 0 ] ; do
- $PS $TERMINATE >&- || { echo done ; break ; }
+ $PS $TERMINATE >/dev/null || { echo done ; break ; }
echo -n "."
$SLEEP 1
[ -n "$WAIT" ] && let WAIT=WAIT-1
@@ -1006,7 +1006,7 @@ while (true) do
done
# Clean up PID file
-[ -n "$RUNVDRPID" ] && rm $RUNVDRPID >&- 2>&-
+[ -n "$RUNVDRPID" ] && rm $RUNVDRPID 2>/dev/null
# Clean up proxy file, if used
-[ -n "$PROXYFILE" ] && rm $PROXYFILE >&- 2>&-
+[ -n "$PROXYFILE" ] && rm $PROXYFILE 2>/dev/null