aboutsummaryrefslogtreecommitdiff
path: root/tools
diff options
context:
space:
mode:
authorceros7 <ceros7@svn>2010-05-16 18:06:49 +0000
committerceros7 <ceros7@svn>2010-05-16 18:06:49 +0000
commita939af2243c080a021c5dc779ef192f26e818153 (patch)
treeaa7a0b9f6ffdfd889092c71d8965c46a99ccceb6 /tools
parent0164dc3fa4aaea2c256f6276105e4d8d86d5ffd1 (diff)
Convert xbmc-standalone script to plain shell script.
git-svn-id: https://xbmc.svn.sourceforge.net/svnroot/xbmc/trunk@30229 568bbfeb-2a22-0410-94d2-cc84cf5bfa90
Diffstat (limited to 'tools')
-rwxr-xr-xtools/Linux/xbmc-standalone.sh10
1 files changed, 5 insertions, 5 deletions
diff --git a/tools/Linux/xbmc-standalone.sh b/tools/Linux/xbmc-standalone.sh
index e5917f9887..e22a4d049a 100755
--- a/tools/Linux/xbmc-standalone.sh
+++ b/tools/Linux/xbmc-standalone.sh
@@ -1,4 +1,4 @@
-#!/bin/bash
+#!/bin/sh
if which pulse-session; then
XBMC="pulse-session xbmc --standalone \"$@\""
else
@@ -9,21 +9,21 @@ LOOP=1
CRASHCOUNT=0
LASTSUCCESSFULSTART=$(date +%s)
ulimit -c unlimited
-while (( $LOOP ))
+while [ $(( $LOOP )) = "1" ]
do
$XBMC
RET=$?
NOW=$(date +%s)
- if (( ($RET >= 64 && $RET <=66) || $RET == 0 )); then # clean exit
+ if [ $(( ($RET >= 64 && $RET <=66) || $RET == 0 )) = "1" ]; then # clean exit
LOOP=0
else # crash
DIFF=$((NOW-LASTSUCCESSFULSTART))
- if (($DIFF > 60 )); then # Not on startup, ignore
+ if [ $(($DIFF > 60 )) = "1" ]; then # Not on startup, ignore
LASTSUCESSFULSTART=$NOW
CRASHCOUNT=0
else # at startup, look sharp
CRASHCOUNT=$((CRASHCOUNT+1))
- if (($CRASHCOUNT >= 3)); then # Too many, bail out
+ if [ $(($CRASHCOUNT >= 3)) = "1" ]; then # Too many, bail out
LOOP=0
echo "XBMC has exited uncleanly 3 times in the ${DIFF}s. Something is probably wrong"
fi