Signed-off-by: Jens Axboe <jens.axboe@oracle.com>
usage();
exit(0);
case 'c':
usage();
exit(0);
case 'c':
- show_cmd_help(options, optarg);
- exit(0);
+ ret = show_cmd_help(options, optarg);
+ exit(ret);
case 'v':
printf("%s\n", fio_version_string);
exit(0);
case 'v':
printf("%s\n", fio_version_string);
exit(0);
"integer value (opt=100)",
"no argument (opt)",
};
"integer value (opt=100)",
"no argument (opt)",
};
while (o->name) {
int match = !strcmp(name, o->name);
if (show_all || match) {
while (o->name) {
int match = !strcmp(name, o->name);
if (show_all || match) {
printf("%s: %s\n", o->name, o->help);
if (match)
printf("type: %s\n", typehelp[o->type]);
printf("%s: %s\n", o->name, o->help);
if (match)
printf("type: %s\n", typehelp[o->type]);
+ printf("No such command: %s\n", name);
+ return 1;