From: Steinar H. Gunderson Date: Sat, 14 Jul 2007 09:18:48 +0000 (+0200) Subject: Fix umount.nfs exit status X-Git-Tag: nfs-utils-1-1-1~152 X-Git-Url: https://git.decadent.org.uk/gitweb/?p=nfs-utils.git;a=commitdiff_plain;h=4cd30380ba2e841511f1cb834a7163671ea1187e Fix umount.nfs exit status Hi, As per a bug report from a user: mount.c seems to assume that nfsumount() uses standard C true/false return values, and inverts them for the exit status (where 0 is traditionally considered success). However, nfsumount() consistently seems to use 0 for success, and thus a success gets returned as exit status 1 and a failure as exit status 0. This confuses at least the GNOME drive manager applet, and probably others as well. Signed-off-by: Steinar H. Gunderson Signed-off-by: Neil Brown --- diff --git a/utils/mount/mount.c b/utils/mount/mount.c index 442ce0e..17c79e4 100644 --- a/utils/mount/mount.c +++ b/utils/mount/mount.c @@ -399,7 +399,7 @@ int main(int argc, char *argv[]) umount_usage(); exit(1); } - exit(nfsumount(argc, argv) ? 0 : 1); + exit(nfsumount(argc, argv)); } if(argv[1] && argv[1][0] == '-') {