[klibc] [PATCH] umount: Add -l option for lazy unmount
Sergey Vlasov
vsu at altlinux.ru
Sun Feb 18 09:44:56 PST 2007
Signed-off-by: Sergey Vlasov <vsu at altlinux.ru>
---
Alternatively, you may pull from the following git repo and branch:
git://git.altlinux.org/people/vsu/packages/klibc.git alt-umount
(branch based on the klibc-1.4.32 release - sorry, forgot to send
this patch earlier)
usr/utils/umount.c | 7 +++++--
1 files changed, 5 insertions(+), 2 deletions(-)
diff --git a/usr/utils/umount.c b/usr/utils/umount.c
index 52aa18a..85497a7 100644
--- a/usr/utils/umount.c
+++ b/usr/utils/umount.c
@@ -17,13 +17,16 @@ int main(int argc, char *argv[])
progname = argv[0];
do {
- c = getopt(argc, argv, "f");
+ c = getopt(argc, argv, "fl");
if (c == EOF)
break;
switch (c) {
case 'f':
flag |= MNT_FORCE;
break;
+ case 'l':
+ flag |= MNT_DETACH;
+ break;
case '?':
fprintf(stderr, "%s: invalid option -%c\n",
progname, optopt);
@@ -32,7 +35,7 @@ int main(int argc, char *argv[])
} while (1);
if (optind + 1 != argc) {
- fprintf(stderr, "Usage: %s [-f] mntpoint\n", progname);
+ fprintf(stderr, "Usage: %s [-f] [-l] mntpoint\n", progname);
return 1;
}
--
1.5.0.57.g09e9d
More information about the klibc
mailing list