X-Git-Url: https://git.decadent.org.uk/gitweb/?p=nfs-utils.git;a=blobdiff_plain;f=utils%2Fmount%2Fmount.c;h=55d60aa63b8298032d44dfdd0b89c949976a5d7d;hp=45428b0c0662cc60400b5935d8d7cb0c1604bdb5;hb=f12ed63e95dec929d6893b16983233d2940a889c;hpb=be73b5afb50ecfda9d85aaac247792b1b7d7dc62 diff --git a/utils/mount/mount.c b/utils/mount/mount.c index 45428b0..55d60aa 100644 --- a/utils/mount/mount.c +++ b/utils/mount/mount.c @@ -443,18 +443,18 @@ int main(int argc, char *argv[]) start_statd(); } - if (fake) - return 0; if (mnt_err) exit(EX_FAIL); - mnt_err = do_mount_syscall(spec, mount_point, - nfs_mount_vers == 4 ? "nfs4" : "nfs", - flags, mount_opts); - - if (mnt_err) { - mount_error(mount_point); - exit(EX_FAIL); + if (!fake) { + mnt_err = do_mount_syscall(spec, mount_point, + nfs_mount_vers == 4 ? "nfs4" : "nfs", + flags, mount_opts); + + if (mnt_err) { + mount_error(mount_point); + exit(EX_FAIL); + } } if (!nomtab)