--- trunk/busybox/splash-functions.rc 2011/01/28 19:39:02 1273 +++ trunk/busybox/splash-functions.rc 2011/02/04 21:30:04 1275 @@ -5,6 +5,9 @@ splash() { + # only run fbsplash if theme was found + [[ ! -e ${SPLASH_THEMES}/${SPLASH_THEME} ]] && return + case $1 in rc_init) rc_init ;; rc_verbose|rc_exit) rc_exit ;; @@ -28,6 +31,7 @@ -f ${SPLASH_FIFO} \ ${SPLASH_OPTS} & + wait_for_fbsplash splash_control "write:${SPLASH_BOOT_MESSAGE}" fi @@ -39,6 +43,7 @@ -f ${SPLASH_FIFO} \ ${SPLASH_OPTS} & + wait_for_fbsplash splash_control "write:${SPLASH_SHUTDOWN_MESSAGE}" fi @@ -50,6 +55,7 @@ -f ${SPLASH_FIFO} \ ${SPLASH_OPTS} & + wait_for_fbsplash splash_control "write:${SPLASH_REBOOT_MESSAGE}" fi fi @@ -70,6 +76,14 @@ fbres } +wait_for_fbsplash() +{ + while [[ -z $(pidof fbsplash) ]] + do + sleep 0.1 + done +} + splash_control() { # only write to fifo if the fbsplash process is runnning @@ -77,6 +91,10 @@ if [[ -n $(pidof fbsplash) ]] then echo "$@" > ${SPLASH_FIFO} + else + # exit here + splash_cursor enable + chvt 1 fi }