Assignment used as truth value in xfrm_del_sa()
and xfrm_get_policy().
Wrong argument type declared for security_xfrm_state_delete()
when SELINUX is disabled.
Signed-off-by: David S. Miller <davem@davemloft.net>
{
}
-static inline int security_xfrm_state_delete(struct xfrm_policy *xp)
+static inline int security_xfrm_state_delete(struct xfrm_state *x)
{
return 0;
}
if (x == NULL)
return -ESRCH;
- if (err = security_xfrm_state_delete(x))
+ if ((err = security_xfrm_state_delete(x)) != 0)
goto out;
if (xfrm_state_kern(x)) {
MSG_DONTWAIT);
}
} else {
- if (err = security_xfrm_policy_delete(xp))
+ if ((err = security_xfrm_policy_delete(xp)) != 0)
goto out;
c.data.byid = p->index;
c.event = nlh->nlmsg_type;