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.
master
Harald Hoyer 2014-12-01 11:50:00 +01:00
parent 3659d64df3
commit fa45d0d9c9
1 changed files with 10 additions and 9 deletions

View File

@ -73,15 +73,16 @@ fi
if command -v kmod >/dev/null 2>/dev/null; then if command -v kmod >/dev/null 2>/dev/null; then
kmod static-nodes --format=tmpfiles 2>/dev/null | \ kmod static-nodes --format=tmpfiles 2>/dev/null | \
while read type file mode a a a majmin; do while read type file mode a a a majmin; do
case $type in type=${type%\!}
d) case $type in
mkdir -m $mode -p $file d)
;; mkdir -m $mode -p $file
c) ;;
mknod -m $mode $file $type ${majmin%:*} ${majmin#*:} c)
;; mknod -m $mode $file $type ${majmin%:*} ${majmin#*:}
esac ;;
done esac
done
fi fi


trap "action_on_fail Signal caught!" 0 trap "action_on_fail Signal caught!" 0