[PATCH] usrmount should skip comments in fstab

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi!

Currently usrmount chokes on fstab lines like:
#... /usr ...
It will try to mount "#...", which obviously is wrong.

Attached patch fixes this by skipping over lines beginning with "#". It still 
does not handle cases like " #...", but is enough to work in my case.

Kind regards,
Dennis
--- /usr/lib/dracut/modules.d/98usrmount/mount-usr.sh.orig	2012-02-25 22:40:15.122000048 +0100
+++ /usr/lib/dracut/modules.d/98usrmount/mount-usr.sh	2012-02-25 23:00:24.452698091 +0100
@@ -10,6 +10,7 @@
     local _dev _mp _fs _opts _rest _usr_found _ret
     # check, if we have to mount the /usr filesystem
     while read _dev _mp _fs _opts _rest; do
+		[ "$_dev" = "${_dev###}" ] || continue
         if [ "$_mp" = "/usr" ]; then
             case "$_dev" in
                 LABEL=*)

Attachment: signature.asc
Description: This is a digitally signed message part.


[Index of Archives]     [Linux Kernel]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux SCSI]

  Powered by Linux