aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMike Frysinger <vapier@gentoo.org>2006-04-21 22:04:05 +0000
committerMike Frysinger <vapier@gentoo.org>2006-04-21 22:04:05 +0000
commit70cbb6e02626608c95a74e74bdc51bbbf7fb570b (patch)
tree04d1aae14aa24819b94bcbfc105aad0f46951152
parent10f55b1daed9ab17c594fa0598aeea8002a70afc (diff)
downloadbusybox-70cbb6e02626608c95a74e74bdc51bbbf7fb570b.tar.gz
Jason Schoon writes: Attached is a patch to display the usage message if fuser is called with no arguments, rather than doing no work and failing silently.
-rw-r--r--procps/fuser.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/procps/fuser.c b/procps/fuser.c
index 850626e42..35d77ed1c 100644
--- a/procps/fuser.c
+++ b/procps/fuser.c
@@ -326,6 +326,9 @@ int fuser_main(int argc, char **argv)
int killsig = SIGTERM;
int success = 1;
+ if (argc < 2)
+ bb_show_usage();
+
fni = xmalloc(sizeof(int));
for(i=1;i<argc;i++) {
optn = fuser_option(argv[i]);