diff options
| author | John W. Linville <linville@tuxdriver.com> | 2006-08-02 14:15:21 -0400 |
|---|---|---|
| committer | John W. Linville <linville@tuxdriver.com> | 2006-08-02 14:15:21 -0400 |
| commit | ebf572b448757190027d8ee34e73deb989ec7b60 (patch) | |
| tree | 2320a92b1aed2c9475e291d75c92616af75e195a /security/selinux/ss/policydb.c | |
| parent | 48c86da1a211ef13bbfb1c8f2e35dda44a66b8a1 (diff) | |
| parent | 49b1e3ea19b1c95c2f012b8331ffb3b169e4c042 (diff) | |
Merge branch 'from-linus' into bcm43xx
Diffstat (limited to 'security/selinux/ss/policydb.c')
| -rw-r--r-- | security/selinux/ss/policydb.c | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/security/selinux/ss/policydb.c b/security/selinux/ss/policydb.c index 0111990ba837..f03960e697ce 100644 --- a/security/selinux/ss/policydb.c +++ b/security/selinux/ss/policydb.c | |||
| @@ -644,10 +644,18 @@ void policydb_destroy(struct policydb *p) | |||
| 644 | kfree(lra); | 644 | kfree(lra); |
| 645 | 645 | ||
| 646 | for (rt = p->range_tr; rt; rt = rt -> next) { | 646 | for (rt = p->range_tr; rt; rt = rt -> next) { |
| 647 | kfree(lrt); | 647 | if (lrt) { |
| 648 | ebitmap_destroy(&lrt->range.level[0].cat); | ||
| 649 | ebitmap_destroy(&lrt->range.level[1].cat); | ||
| 650 | kfree(lrt); | ||
| 651 | } | ||
| 648 | lrt = rt; | 652 | lrt = rt; |
| 649 | } | 653 | } |
| 650 | kfree(lrt); | 654 | if (lrt) { |
| 655 | ebitmap_destroy(&lrt->range.level[0].cat); | ||
| 656 | ebitmap_destroy(&lrt->range.level[1].cat); | ||
| 657 | kfree(lrt); | ||
| 658 | } | ||
| 651 | 659 | ||
| 652 | if (p->type_attr_map) { | 660 | if (p->type_attr_map) { |
| 653 | for (i = 0; i < p->p_types.nprim; i++) | 661 | for (i = 0; i < p->p_types.nprim; i++) |
