summaryrefslogtreecommitdiffstats
path: root/initramfs
diff options
context:
space:
mode:
Diffstat (limited to 'initramfs')
-rw-r--r--initramfs/initrd-stuff/etc/functions4
-rwxr-xr-xinitramfs/initrd-stuff/init8
2 files changed, 8 insertions, 4 deletions
diff --git a/initramfs/initrd-stuff/etc/functions b/initramfs/initrd-stuff/etc/functions
index 4aa9cef4..285f2d46 100644
--- a/initramfs/initrd-stuff/etc/functions
+++ b/initramfs/initrd-stuff/etc/functions
@@ -558,7 +558,9 @@ runinithook () {
local hook=$1
if [ -d /etc/init-hooks/$hook ]; then
for hook_script in /etc/init-hooks/$hook/*.sh; do
- . $hook_script
+ if [ -e $hook_script ]; then
+ . $hook_script
+ fi
done
fi
}
diff --git a/initramfs/initrd-stuff/init b/initramfs/initrd-stuff/init
index cef0206e..ca12c480 100755
--- a/initramfs/initrd-stuff/init
+++ b/initramfs/initrd-stuff/init
@@ -791,9 +791,11 @@ runinithook '70-before-plugins'
# check for any plugin-specific runlevel scripts and run them, if found:
if [ -d /etc/plugin-init.d ]; then
for plugin_starter in /etc/plugin-init.d/*.sh; do
- [ $DEBUGLEVEL -gt 0 ] \
- && echo "Running plugin starter $plugin_starter ..."
- . $plugin_starter
+ if [ -e $plugin_starter ]; then
+ [ $DEBUGLEVEL -gt 0 ] \
+ && echo "Running plugin starter $plugin_starter ..."
+ . $plugin_starter
+ fi
done
fi