summaryrefslogtreecommitdiff
path: root/security/selinux
diff options
context:
space:
mode:
authorJames Morris <james.l.morris@oracle.com>2015-11-26 15:04:19 +1100
committerJames Morris <james.l.morris@oracle.com>2015-11-26 15:04:19 +1100
commit6e37592900f1e75c2031ec10886f4858a260aeec (patch)
tree6835898fc94ddcf1988e539da0270657739c836a /security/selinux
parent096fe9eaea40a17e125569f9e657e34cdb6d73bd (diff)
parentf3bef67992e8698897b584616535803887c4a73e (diff)
Merge branch 'upstream' of git://git.infradead.org/users/pcmoore/selinux into for-linus2
Diffstat (limited to 'security/selinux')
-rw-r--r--security/selinux/ss/conditional.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/security/selinux/ss/conditional.c b/security/selinux/ss/conditional.c
index 18643bf9894d..456e1a9bcfde 100644
--- a/security/selinux/ss/conditional.c
+++ b/security/selinux/ss/conditional.c
@@ -638,7 +638,7 @@ void cond_compute_av(struct avtab *ctab, struct avtab_key *key,
{
struct avtab_node *node;
- if (!ctab || !key || !avd || !xperms)
+ if (!ctab || !key || !avd)
return;
for (node = avtab_search_node(ctab, key); node;
@@ -657,7 +657,7 @@ void cond_compute_av(struct avtab *ctab, struct avtab_key *key,
if ((u16)(AVTAB_AUDITALLOW|AVTAB_ENABLED) ==
(node->key.specified & (AVTAB_AUDITALLOW|AVTAB_ENABLED)))
avd->auditallow |= node->datum.u.data;
- if ((node->key.specified & AVTAB_ENABLED) &&
+ if (xperms && (node->key.specified & AVTAB_ENABLED) &&
(node->key.specified & AVTAB_XPERMS))
services_compute_xperms_drivers(xperms, node);
}