xbps-query: show usage() when called with no args.

This commit is contained in:
Juan RP 2012-11-19 21:06:37 +01:00
parent 5de4fb1f0a
commit ca26c20dd5

View File

@ -169,7 +169,7 @@ main(int argc, char **argv)
}
if (!opmode && argc > optind)
show = true;
else if (opmode && (argc == optind))
else if (argc == 1 || (opmode && (argc == optind)))
usage(true);
else if ((search || own) && (argc == optind))
usage(true);