From: Harald Hoyer Date: Mon, 1 Dec 2014 10:50:00 +0000 (+0100) Subject: base/init.sh: ignore exclamation mark for kmod static-nodes X-Git-Tag: 041~80 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=fa45d0d9c9109f3c2953ad02d7e3aa69c4e09add;p=thirdparty%2Fdracut.git base/init.sh: ignore exclamation mark for kmod static-nodes newer versions add an exclamation mark for the type, to mark it to be created on boot only. --- diff --git a/modules.d/99base/init.sh b/modules.d/99base/init.sh index 3afe6d509..5f66d1fc9 100755 --- a/modules.d/99base/init.sh +++ b/modules.d/99base/init.sh @@ -73,15 +73,16 @@ fi if command -v kmod >/dev/null 2>/dev/null; then kmod static-nodes --format=tmpfiles 2>/dev/null | \ while read type file mode a a a majmin; do - case $type in - d) - mkdir -m $mode -p $file - ;; - c) - mknod -m $mode $file $type ${majmin%:*} ${majmin#*:} - ;; - esac - done + type=${type%\!} + case $type in + d) + mkdir -m $mode -p $file + ;; + c) + mknod -m $mode $file $type ${majmin%:*} ${majmin#*:} + ;; + esac + done fi trap "action_on_fail Signal caught!" 0