git: 73cecc0ef78e - main - MAC/do: Move destroy() to a better place
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Mon, 16 Dec 2024 14:45:52 UTC
The branch main has been updated by olce:
URL: https://cgit.FreeBSD.org/src/commit/?id=73cecc0ef78e49295cd9cd8df1bf271f5b8c437d
commit 73cecc0ef78e49295cd9cd8df1bf271f5b8c437d
Author: Olivier Certner <olce@FreeBSD.org>
AuthorDate: 2024-07-03 13:52:33 +0000
Commit: Olivier Certner <olce@FreeBSD.org>
CommitDate: 2024-12-16 14:42:35 +0000
MAC/do: Move destroy() to a better place
No functional change intended.
Reviewed by: bapt
Approved by: markj (mentor)
Sponsored by: The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D47604
---
sys/security/mac_do/mac_do.c | 12 ++++++------
1 file changed, 6 insertions(+), 6 deletions(-)
diff --git a/sys/security/mac_do/mac_do.c b/sys/security/mac_do/mac_do.c
index 8ce84d7ba099..cb166cfd6128 100644
--- a/sys/security/mac_do/mac_do.c
+++ b/sys/security/mac_do/mac_do.c
@@ -329,12 +329,6 @@ SYSCTL_PROC(_security_mac_do, OID_AUTO, rules,
0, 0, sysctl_rules, "A",
"Rules");
-static void
-destroy(struct mac_policy_conf *mpc)
-{
- osd_jail_deregister(mac_do_osd_jail_slot);
-}
-
static int
mac_do_prison_set(void *obj, void *data)
{
@@ -452,6 +446,12 @@ init(struct mac_policy_conf *mpc)
sx_sunlock(&allprison_lock);
}
+static void
+destroy(struct mac_policy_conf *mpc)
+{
+ osd_jail_deregister(mac_do_osd_jail_slot);
+}
+
static bool
rule_applies(struct ucred *cred, struct rule *r)
{