2
0
mirror of https://gitlab.com/apparmor/apparmor synced 2025-08-31 06:16:03 +00:00

libapparmor: prepare to allow a cache to have overlay directory locations

Make the internal cache dir tracking use a fixed array and update
all references to the internal dirfd to index the array.

Signed-off-by: John Johansen <john.johansen@canonical.com>
Acked-by: Christian Boltz <apparmor@cboltz.de>
This commit is contained in:
John Johansen
2018-02-28 10:09:50 -08:00
parent bf662b5594
commit 2ad924f2b1
3 changed files with 45 additions and 16 deletions

View File

@@ -1164,7 +1164,7 @@ int main(int argc, char *argv[])
write_cache = 0;
skip_read_cache = 1;
} else {
cachedir = aa_policy_cache_dir_path(policy_cache);
cachedir = aa_policy_cache_dir_path(policy_cache, 0);
if (!cachedir) {
PERROR("Policy cache disabled: Cannot locate the policy cache directory: %m\n");