diff options
author | Neil Brown <neilb@suse.de> | 2007-10-11 11:29:07 +1000 |
---|---|---|
committer | Neil Brown <neilb@suse.de> | 2007-10-11 11:29:07 +1000 |
commit | df0a06a985a15f088d0a7fb39c61a98e6aac9830 (patch) | |
tree | bb6c473b95598801c8ba9031af4c4f5a212a3e24 | |
parent | 4d5e8d3e948a83e3960d63ff2d537a62bee4fa4a (diff) | |
download | nfs-utils-df0a06a985a15f088d0a7fb39c61a98e6aac9830.tar.gz nfs-utils-df0a06a985a15f088d0a7fb39c61a98e6aac9830.tar.xz nfs-utils-df0a06a985a15f088d0a7fb39c61a98e6aac9830.zip |
Don't fail an unmount just because we couldn't contact the NFS server.
If we fail to talk to the NFS server when unmounted a v2 or v3 mount,
still do the unmount, but allow the error to propagate up.
Signed-off-by: Neil Brown <neilb@suse.de>
-rw-r--r-- | utils/mount/nfsumount.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/utils/mount/nfsumount.c b/utils/mount/nfsumount.c index 8902f00..9e9cd16 100644 --- a/utils/mount/nfsumount.c +++ b/utils/mount/nfsumount.c @@ -350,8 +350,7 @@ int nfsumount(int argc, char *argv[]) if (mc) { if (!lazy && strcmp(mc->m.mnt_type, "nfs4") != 0) ret = do_nfs_umount(mc->m.mnt_fsname, mc->m.mnt_opts); - if (!ret || force) - ret = del_mtab(mc->m.mnt_fsname, mc->m.mnt_dir); + ret = del_mtab(mc->m.mnt_fsname, mc->m.mnt_dir) ?: ret; } else if (*spec != '/') { if (!lazy) ret = do_nfs_umount(spec, "tcp,v3"); |