]> git.ipfire.org Git - thirdparty/util-linux.git/commitdiff
lslogins: tell why command failed
authorSami Kerola <kerolasa@iki.fi>
Sat, 13 Dec 2014 16:41:06 +0000 (16:41 +0000)
committerSami Kerola <kerolasa@iki.fi>
Fri, 19 Dec 2014 09:11:02 +0000 (09:11 +0000)
Printing usage() without hint what is wrong does not help an user.

Signed-off-by: Sami Kerola <kerolasa@iki.fi>
login-utils/lslogins.c

index 85fd7c8346258bc5b8f2dfb3992f7a91be57509d..7fe6599d61fb01a6765a13002bbc40b71b1b543d 100644 (file)
@@ -1437,7 +1437,7 @@ int main(int argc, char *argv[])
                logins = argv[optind];
                outmode = OUT_PRETTY;
        } else if (argc != optind)
-               usage(stderr);
+               errx(EXIT_FAILURE, _("Only one user may be specified. Use -l for multiple users."));
 
        scols_init_debug(0);