aboutsummaryrefslogtreecommitdiff
path: root/sh/rc-mount.sh
diff options
context:
space:
mode:
authorRoy Marples <roy@marples.name>2007-11-28 15:45:03 +0000
committerRoy Marples <roy@marples.name>2007-11-28 15:45:03 +0000
commitac9279cc0d5a00bc17908b2914941186020cd3ce (patch)
tree850a4fe19917113e75bfd2e79d00b58208468503 /sh/rc-mount.sh
parent444f23e2d158389b22d40537fc9b027d9f575229 (diff)
Massive whitespace cleanup
Diffstat (limited to 'sh/rc-mount.sh')
-rw-r--r--sh/rc-mount.sh14
1 files changed, 7 insertions, 7 deletions
diff --git a/sh/rc-mount.sh b/sh/rc-mount.sh
index 2f85cbf0..19f469e0 100644
--- a/sh/rc-mount.sh
+++ b/sh/rc-mount.sh
@@ -32,7 +32,7 @@ do_unmount() {
local cmd="$1" retval=0 retry=
local f_opts="-m -c" f_kill="-s " mnt=
- if [ "${RC_UNAME}" = "Linux" ] ; then
+ if [ "${RC_UNAME}" = "Linux" ]; then
f_opts="-m"
f_kill="-"
fi
@@ -57,24 +57,24 @@ do_unmount() {
esac
retry=3
- while ! LC_ALL=C ${cmd} "${mnt}" 2>/dev/null ; do
+ while ! LC_ALL=C ${cmd} "${mnt}" 2>/dev/null; do
# Don't kill if it's us (/ and possibly /usr)
local pids="$(fuser ${f_opts} "${mnt}" 2>/dev/null)"
case " ${pids} " in
- *" $$ "*) retry=0 ;;
- " ") eend 1 "in use but fuser finds nothing"; retry=0 ;;
+ *" $$ "*) retry=0;;
+ " ") eend 1 "in use but fuser finds nothing"; retry=0;;
*)
local sig="KILL"
[ ${retry} -gt 0 ] && sig="TERM"
fuser ${f_kill}${sig} -k ${f_opts} "${mnt}" \
- >/dev/null 2>/dev/null
+ >/dev/null 2>&1
sleep 1
retry=$((${retry} - 1))
;;
esac
# OK, try forcing things
- if [ ${retry} -le 0 ] ; then
+ if [ ${retry} -le 0 ]; then
case "${cmd}" in
umount*)
LC_ALL=C ${cmd} -f "${mnt}" || retry=-999
@@ -86,7 +86,7 @@ do_unmount() {
break
fi
done
- if [ ${retry} -eq -999 ] ; then
+ if [ ${retry} -eq -999 ]; then
eend 1
retval=1
else