diff options
| author | John Johansen <john.johansen@canonical.com> | 2025-02-17 01:46:37 -0800 |
|---|---|---|
| committer | John Johansen <john.johansen@canonical.com> | 2025-07-20 02:31:06 -0700 |
| commit | 9afdc6abb007d5a86f54e9f10870ac1468155ca5 (patch) | |
| tree | ca4322b73a8c95da56d8e0866ef2c490791ffdd1 /security/apparmor/ipc.c | |
| parent | f9c9dce01e9640d94a37304bddc97b738ee4ac35 (diff) | |
apparmor: transition from a list of rules to a vector of rules
The set of rules on a profile is not dynamically extended, instead
if a new ruleset is needed a new version of the profile is created.
This allows us to use a vector of rules instead of a list, slightly
reducing memory usage and simplifying the code.
Signed-off-by: John Johansen <john.johansen@canonical.com>
Diffstat (limited to 'security/apparmor/ipc.c')
| -rw-r--r-- | security/apparmor/ipc.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/security/apparmor/ipc.c b/security/apparmor/ipc.c index 3566d875645e..df5712cea685 100644 --- a/security/apparmor/ipc.c +++ b/security/apparmor/ipc.c @@ -80,8 +80,7 @@ static int profile_signal_perm(const struct cred *cred, struct aa_label *peer, u32 request, struct apparmor_audit_data *ad) { - struct aa_ruleset *rules = list_first_entry(&profile->rules, - typeof(*rules), list); + struct aa_ruleset *rules = profile->label.rules[0]; struct aa_perms perms; aa_state_t state; |
