summaryrefslogtreecommitdiffstats
path: root/sys/security/mac/mac_label.c
diff options
context:
space:
mode:
authorrwatson <rwatson@FreeBSD.org>2006-12-20 23:13:04 +0000
committerrwatson <rwatson@FreeBSD.org>2006-12-20 23:13:04 +0000
commitf30462f07d120659ae673b3b6fb145d8d60bed15 (patch)
treebdb1023f8c9b28d91ad46cfccabb3420ce643455 /sys/security/mac/mac_label.c
parent65458541b7844258d4f9b50d7b8900d83598fd22 (diff)
downloadFreeBSD-src-f30462f07d120659ae673b3b6fb145d8d60bed15.zip
FreeBSD-src-f30462f07d120659ae673b3b6fb145d8d60bed15.tar.gz
Staticize and comment zone_label.
Obtained from: TrustedBSD Project
Diffstat (limited to 'sys/security/mac/mac_label.c')
-rw-r--r--sys/security/mac/mac_label.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/sys/security/mac/mac_label.c b/sys/security/mac/mac_label.c
index 572d598..9e162a4 100644
--- a/sys/security/mac/mac_label.c
+++ b/sys/security/mac/mac_label.c
@@ -44,7 +44,13 @@ __FBSDID("$FreeBSD$");
#include <security/mac/mac_framework.h>
#include <security/mac/mac_internal.h>
-uma_zone_t zone_label;
+/*
+ * zone_label is the UMA zone from which all labels are allocated. Label
+ * structures are initialized to zero bytes so that policies see a NULL/0
+ * slot on first use, even if the policy is loaded after the label is
+ * allocated for an object.
+ */
+static uma_zone_t zone_label;
static int mac_labelzone_ctor(void *mem, int size, void *arg, int flags);
static void mac_labelzone_dtor(void *mem, int size, void *arg);
OpenPOWER on IntegriCloud