diff --git a/pam_usb/src/pamusb-check.c b/pam_usb/src/pamusb-check.c index d7a28e9..2c6252d 100644 --- a/pam_usb/src/pamusb-check.c +++ b/pam_usb/src/pamusb-check.c @@ -90,13 +90,13 @@ int main(int argc, char **argv) extern char *optarg; char *short_options = "hc:s:dqD"; struct option long_options[] = { - { "help", 0, 0, 0}, - { "config", 1, 0, 0}, - { "service", 1, 0, 0}, - { "dump", 0, &dump, 1 }, - { "quiet", 0, &quiet, 1}, - { "debug", 0, &debug, 1}, - { 0, 0, 0, 0} + { "help", 0, 0, 0 }, + { "config", 1, 0, 0 }, + { "service", 1, 0, 0 }, + { "dump", 0, 0, 0 }, + { "quiet", 0, 0, 0 }, + { "debug", 0, 0, 0 }, + { 0, 0, 0, 0 } }; while ((opt = getopt_long(argc, argv, short_options, long_options, @@ -111,6 +111,12 @@ int main(int argc, char **argv) conf_file = optarg; else if (opt == 's' || (!opt && !strcmp(long_options[opt_index].name, "service"))) service = optarg; + else if (opt == 'd' || (!opt && !strcmp(long_options[opt_index].name, "dump"))) + dump = 1; + else if (opt == 'q' || (!opt && !strcmp(long_options[opt_index].name, "quiet"))) + quiet = 1; + else if (opt == 'D' || (!opt && !strcmp(long_options[opt_index].name, "debug"))) + debug = 1; else if (opt == '?') { pusb_check_usage(argv[0]);