mirror of
https://gitlab.com/apparmor/apparmor
synced 2025-08-30 13:58:22 +00:00
Update option parsing for help to add in Short flag form and Optimize
help.
This commit is contained in:
@@ -254,8 +254,12 @@ static int process_args(int argc, char *argv[])
|
|||||||
case 'h':
|
case 'h':
|
||||||
if (!optarg) {
|
if (!optarg) {
|
||||||
display_usage(progname);
|
display_usage(progname);
|
||||||
} else if (strcmp(optarg, "dump") == 0) {
|
} else if (strcmp(optarg, "dump") == 0 ||
|
||||||
|
strcmp(optarg, "D") == 0) {
|
||||||
display_dump(progname);
|
display_dump(progname);
|
||||||
|
} else if (strcmp(optarg, "Optimize") == 0 ||
|
||||||
|
strcmp(optarg, "O") == 0) {
|
||||||
|
display_optimize(progname);
|
||||||
} else {
|
} else {
|
||||||
PERROR("%s: Invalid --help option %s\n",
|
PERROR("%s: Invalid --help option %s\n",
|
||||||
progname, optarg);
|
progname, optarg);
|
||||||
|
Reference in New Issue
Block a user