mirror of
https://gitlab.com/apparmor/apparmor
synced 2025-08-31 06:16:03 +00:00
Fix to stop leaking the dfa ruleset. On large policies containing lots of
hats this will result in a marked improvement on memory usage.
This commit is contained in:
@@ -602,7 +602,9 @@ int process_regex(struct codomain *cod)
|
||||
|
||||
if (regex_type == AARE_DFA && cod->dfarule_count > 0) {
|
||||
cod->dfa = aare_create_dfa(cod->dfarules, 0, &cod->dfa_size);
|
||||
if (!cod->dfa)
|
||||
aare_delete_ruleset(cod->dfarules);
|
||||
cod->dfarules = NULL;
|
||||
if (!cod->dfa)
|
||||
goto out;
|
||||
/*
|
||||
if (cod->dfa_size == 0) {
|
||||
|
Reference in New Issue
Block a user