mirror of
https://github.com/eosswedenorg/antelope-keygen
synced 2026-07-04 12:03:41 +02:00
src/main.cpp: make sure we can parse "--l33t" and "--threads" in any order.
This commit is contained in:
parent
f3bf4bdab1
commit
152015d959
1 changed files with 22 additions and 15 deletions
|
|
@ -122,10 +122,15 @@ int main(int argc, char **argv) {
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!strcmp(argv[p], "search")) {
|
if (!strcmp(argv[p], "search")) {
|
||||||
|
bool parse_opt;
|
||||||
p++;
|
p++;
|
||||||
|
|
||||||
|
|
||||||
|
do {
|
||||||
|
parse_opt = false;
|
||||||
if (p < argc && !strcmp(argv[p], "--l33t")) {
|
if (p < argc && !strcmp(argv[p], "--l33t")) {
|
||||||
option_l33t = true;
|
option_l33t = true;
|
||||||
|
parse_opt = true;
|
||||||
p++;
|
p++;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -142,7 +147,9 @@ int main(int argc, char **argv) {
|
||||||
<< " thread support. this option is ignored." << std::endl;
|
<< " thread support. this option is ignored." << std::endl;
|
||||||
#endif /* HAVE_THREADS */
|
#endif /* HAVE_THREADS */
|
||||||
p++;
|
p++;
|
||||||
|
parse_opt = true;
|
||||||
}
|
}
|
||||||
|
} while(parse_opt && p < argc);
|
||||||
|
|
||||||
if (argc <= p) {
|
if (argc <= p) {
|
||||||
std::cerr << "You must specify a word list." << std::endl;
|
std::cerr << "You must specify a word list." << std::endl;
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue