2
0
mirror of https://gitlab.com/apparmor/apparmor synced 2025-08-22 10:07:12 +00:00

add missing 'break' in load_profile()

'case OPTION_OFILE' missed the 'break', which means if did fallthrough
to the default case.

Adding the 'break' means no longer executing another PERROR, and no
longer executing the 'exit(1)' in the default branch.

References: coverity #55994
This commit is contained in:
Christian Boltz 2018-07-13 15:21:24 +02:00
parent aa42e33860
commit c437e9d4a5
No known key found for this signature in database
GPG Key ID: C6A682EA63C82F1C

View File

@ -118,6 +118,7 @@ int load_profile(int option, aa_kernel_interface *kernel_interface,
case OPTION_OFILE:
PERROR(_("%s: Unable to write to output file\n"),
progname);
break;
default:
PERROR(_("%s: ASSERT: Invalid option: %d\n"),
progname, option);