cpp,tests: Actually parse the --with-secret option
* lang/cpp/tests/run-keylist.cpp (main): Handle --with-secret option. Print error for unknown option. -- The --with-secret option was already listed in the help. Now it also works. GnuPG-bug-id: 5965
This commit is contained in:
parent
9e8c8e448e
commit
e029fd2735
@ -119,6 +119,9 @@ main (int argc, char **argv)
|
||||
} else if (!strcmp (*argv, "--locate")) {
|
||||
argc--; argv++;
|
||||
mode |= KeyListMode::Locate;
|
||||
} else if (!strcmp (*argv, "--with-secret")) {
|
||||
argc--; argv++;
|
||||
mode |= KeyListMode::WithSecret;
|
||||
} else if (!strcmp (*argv, "--force-extern")) {
|
||||
argc--; argv++;
|
||||
mode |= KeyListMode::ForceExtern;
|
||||
@ -126,6 +129,7 @@ main (int argc, char **argv)
|
||||
argc--; argv++;
|
||||
mode |= KeyListMode::LocateExternal;
|
||||
} else if (!strncmp (*argv, "--", 2)) {
|
||||
std::cerr << "Error: Unknown option: " << *argv << std::endl;
|
||||
show_usage (1);
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user