Skip to content

Commit

Permalink
alphabetCreator: Allow missing -a option, defaulting to /dev/null (eq…
Browse files Browse the repository at this point in the history
…uals

an empty file).
  • Loading branch information
magnumripper committed Mar 29, 2017
1 parent 42819f6 commit 7ede436
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions src/cmdlineAlphabetCreator.c.in
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ const char *gengetopt_args_info_help[] = {
"\nInput Files:",
" --pwList=filename Password list for creating the alphabet (mandatory)",
" -s, --size=INT Defines the alphabet size. The value should be in\n range 1 to 256 (mandatory)",
" -a, --alphabet=filename Defines the file containing the alphabet (mandatory)",
" -a, --alphabet=filename Defines the file containing the input alphabet",
" -o, --output=filename Defines the output file for the build alphabet\n (mandatory)",
"\nOutput Modes:",
" -w, --printWarnings prints warnings (default=off)",
Expand Down Expand Up @@ -376,8 +376,7 @@ cmdline_parser_required2 (struct gengetopt_args_info *args_info, const char *pro

if (! args_info->alphabet_given)
{
fprintf (stderr, "%s: '--alphabet' ('-a') option required%s\n", prog_name, (additional_error ? additional_error : ""));
error_occurred = 1;
args_info->alphabet_arg = strdup("/dev/null");
}

if (! args_info->output_given)
Expand Down

0 comments on commit 7ede436

Please # to comment.