Return proper error message if recording device is not specified.
MFC after: 1 week
This commit is contained in:
parent
94fce84763
commit
19e79b284d
@ -193,13 +193,18 @@ main(int argc, char *argv[])
|
||||
argc--;
|
||||
argv++;
|
||||
continue;
|
||||
} else if (argc > 1 && strcmp("rec", *argv + 1) == 0) {
|
||||
} else if (strcmp("rec", *argv + 1) == 0) {
|
||||
if (**argv != '+' && **argv != '-' &&
|
||||
**argv != '=' && **argv != '^') {
|
||||
warnx("unknown modifier: %c", **argv);
|
||||
dusage = 1;
|
||||
break;
|
||||
}
|
||||
if (argc <= 1) {
|
||||
warnx("no recording device specified");
|
||||
dusage = 1;
|
||||
break;
|
||||
}
|
||||
if ((dev = res_name(argv[1], recmask)) == -1) {
|
||||
warnx("unknown recording device: %s", argv[1]);
|
||||
dusage = 1;
|
||||
|
Loading…
x
Reference in New Issue
Block a user