diff options
Diffstat (limited to 'rc.d/init.d')
-rwxr-xr-x | rc.d/init.d/single | 13 |
1 files changed, 7 insertions, 6 deletions
diff --git a/rc.d/init.d/single b/rc.d/init.d/single index df645e7e..64c6806d 100755 --- a/rc.d/init.d/single +++ b/rc.d/init.d/single @@ -29,15 +29,16 @@ fi # If they want to run something in single user mode, might as well run it... for i in /etc/rc1.d/S[0-9][0-9]* ; do # Check if the script is there. - [ -f "$i" ] || continue + [ -x "$i" ] || continue - # Don't run [KS]??foo.{rpmsave,rpmorig} scripts - [ "${i%.rpmsave}" != "$i" ] && continue - [ "${i%.rpmorig}" != "$i" ] && continue - [ "${i%.rpmnew}" != "$i" ] && continue + # Reject backup files and files generated by rpm. + case "$1" in + *.rpmsave|*.rpmorig|*.rpmnew|*~|*.orig) + continue;; + esac [ "$i" = "/etc/rc1.d/S00single" ] && continue $i start -done +done # Now go to the single user level. echo $"Telling INIT to go to single user mode." |