[systemd-devel] [PATCH] fstab-generator: Do not try to fsck non-devices

Thomas Bächler thomas at archlinux.org
Sat Dec 21 02:22:37 PST 2013


This fixes a regression introduced in 64e70e4 where the mount fails
when fstab is misconfigured with fs_passno > 0 on a virtual file
system like tmpfs.
---
 src/fstab-generator/fstab-generator.c | 8 +++++---
 1 file changed, 5 insertions(+), 3 deletions(-)

diff --git a/src/fstab-generator/fstab-generator.c b/src/fstab-generator/fstab-generator.c
index 1227f08..709a1c3 100644
--- a/src/fstab-generator/fstab-generator.c
+++ b/src/fstab-generator/fstab-generator.c
@@ -255,9 +255,11 @@ static int add_mount(
                         "Before=%s\n",
                         post);
 
-        r = add_fsck(f, what, where, type, passno);
-        if (r < 0)
-                return r;
+        if(is_device_path(what)) {
+                r = add_fsck(f, what, where, type, passno);
+                if (r < 0)
+                        return r;
+        }
 
         fprintf(f,
                 "\n"
-- 
1.8.5.2



More information about the systemd-devel mailing list