Date: Mon, 27 Oct 2008 18:08:13 +0000 (UTC) From: Robert Watson <rwatson@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r184367 - head/sys/security/mac_bsdextended Message-ID: <200810271808.m9RI8Di9048109@svn.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: rwatson Date: Mon Oct 27 18:08:12 2008 New Revision: 184367 URL: http://svn.freebsd.org/changeset/base/184367 Log: When the mac_bsdextended policy is unloaded, free rule memory. Obtained from: TrustedBSD Project MFC after: 3 days Modified: head/sys/security/mac_bsdextended/mac_bsdextended.c Modified: head/sys/security/mac_bsdextended/mac_bsdextended.c ============================================================================== --- head/sys/security/mac_bsdextended/mac_bsdextended.c Mon Oct 27 18:05:26 2008 (r184366) +++ head/sys/security/mac_bsdextended/mac_bsdextended.c Mon Oct 27 18:08:12 2008 (r184367) @@ -214,7 +214,12 @@ ugidfw_init(struct mac_policy_conf *mpc) static void ugidfw_destroy(struct mac_policy_conf *mpc) { + int i; + for (i = 0; i < MAC_BSDEXTENDED_MAXRULES; i++) { + if (rules[i] != NULL) + free(rules[i], M_MACBSDEXTENDED); + } mtx_destroy(&ugidfw_mtx); }
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200810271808.m9RI8Di9048109>