mirror of
https://gitlab.com/apparmor/apparmor
synced 2025-08-31 06:16:03 +00:00
This patch prevents the parser from segv'ing if neither of the expected default profile directories exist (/etc/subdomain.d, /etc/apparmor.d). A profile passed on the command line or via stdin will still load, so long as -I/path/to/includes is passed for any relevant includes files.
This commit is contained in:
@@ -191,7 +191,7 @@ int add_search_dir(char *dir)
|
||||
return 0;
|
||||
}
|
||||
|
||||
if (strlen(dir) <= 0)
|
||||
if (!dir || strlen(dir) <= 0)
|
||||
return 1;
|
||||
|
||||
t = malloc(strlen(dir) + 1);
|
||||
|
Reference in New Issue
Block a user