]> git.ipfire.org Git - thirdparty/dracut.git/commitdiff
fix fstab-sys module check
authorDave Young <dyoung@redhat.com>
Thu, 2 Feb 2012 07:59:56 +0000 (15:59 +0800)
committerHarald Hoyer <harald@redhat.com>
Tue, 7 Feb 2012 11:14:21 +0000 (12:14 +0100)
If /etc/fstab.sys does not exist installing fstab-sys module will fail.
Fix this by checking use_fstab and fstab_lines as well

Signed-off-by: Dave Young <dyoung@redhat.com>
dracut
modules.d/95fstab-sys/module-setup.sh

diff --git a/dracut b/dracut
index db97b5861a78ac2ed702bb138ea22fff5eb429ee..f74432e58d25996cf8961b800d9ea8b69e11dd7f 100755 (executable)
--- a/dracut
+++ b/dracut
@@ -598,7 +598,7 @@ done
 export initdir dracutbasedir dracutmodules drivers \
     fw_dir drivers_dir debug no_kernel kernel_only \
     add_drivers mdadmconf lvmconf filesystems \
-    use_fstab libdir usrlibdir fscks nofscks cttyhack \
+    use_fstab fstab_lines libdir usrlibdir fscks nofscks cttyhack \
     stdloglvl sysloglvl fileloglvl kmsgloglvl logfile \
     debug host_fs_types host_devs sshkey
 
index ea9db8338f6050506d5a7b8a076f92d5340ab7b9..0dc12f3e9bf886367dd0ec1b2bf1c2766cbf3784 100755 (executable)
@@ -3,7 +3,7 @@
 # ex: ts=8 sw=4 sts=4 et filetype=sh
 
 check() {
-    test -f /etc/fstab.sys
+    test -f /etc/fstab.sys || [[ -n $use_fstab  ||  -n $fstab_lines ]]
 }
 
 depends() {