busybox: make 'safe shutdown' ash compatible

This commit is contained in:
Stefan Saraev 2013-05-27 21:24:33 +03:00 committed by Stephan Raue
parent 0df78a29dc
commit 9963ca92da

View File

@ -24,7 +24,7 @@
################################################################################
add_omit_pids() {
omit_pids+=( $@ )
omit_pids="$omit_pids -o $1"
}
_shutdown_script () {
@ -41,11 +41,11 @@
_shutdown_script
add_omit_pids $(pidof connmand)
add_omit_pids $(pidof dbus-daemon)
killall5 -15 ${omit_pids[@]/#/-o }
killall5 -15 $omit_pids
for seq in `seq 1 10` ; do
usleep 500000
clear > /dev/tty1
killall5 -18 ${omit_pids[@]/#/-o } || break
killall5 -18 $omit_pids || break
done
sync
umount -a >/dev/null 2>&1