From 48897dfeb90a2c09949c7e9679c3edfbe92a5eec Mon Sep 17 00:00:00 2001 From: Christopher Faylor Date: Sun, 12 May 2002 04:29:54 +0000 Subject: * mount.cc (do_mount): Default to non-exec option for remote drives. Report warnings before attempting a mount. (longopts): Add no-executable option. (mount_commands): Ditto. (opts): Ditto. (usage): Ditto. Indicate that system mount is now the default. (main): Accommodate no-executable option. Make system mount the default. * umount.cc (usage): Indicate that system umount is now the default. (main): Make system umount the default. --- winsup/utils/umount.cc | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'winsup/utils/umount.cc') diff --git a/winsup/utils/umount.cc b/winsup/utils/umount.cc index cff08c70a..459134dc0 100644 --- a/winsup/utils/umount.cc +++ b/winsup/utils/umount.cc @@ -43,7 +43,7 @@ usage (void) fprintf (stderr, "Usage %s [OPTION] []\n\ -A, --remove-all-mounts remove all mounts\n\ -c, --remove-cygdrive-prefix remove cygdrive prefix\n\ - -s, --system remove system mount\n\ + -s, --system remove system mount (default)\n\ -S, --remove-system-mounts remove all system mounts\n\ -u, --user remove user mount\n\ -U, --remove-user-mounts remove all user mounts\n\ @@ -63,6 +63,7 @@ main (int argc, char **argv) { int i; int flags = 0; + int default_flag = MOUNT_SYSTEM; progname = argv[0]; enum do_what { @@ -99,6 +100,7 @@ main (int argc, char **argv) break; case 'u': flags &= ~MOUNT_SYSTEM; + default_flag = 0; break; case 'U': if (do_what != nada) @@ -134,7 +136,7 @@ main (int argc, char **argv) default: if (optind != argc - 1) usage (); - if (cygwin_umount (argv[optind], flags) != 0) + if (cygwin_umount (argv[optind], flags | default_flag) != 0) error (argv[optind]); } -- cgit v1.2.3