On Fri, 8 Sep 2006, Venkat Yekkirala wrote:

> -static inline int xfrm6_policy_check(struct sock *sk, int dir, struct sk_buff
> *skb)
> -{
> -     return xfrm_policy_check(sk, dir, skb, AF_INET6);
> +     if (sk && sk->sk_policy[XFRM_POLICY_IN])
> +             ret = __xfrm_policy_check(sk, dir, skb, family);
> +     else
> +             ret = (!xfrm_policy_count[dir] && !skb->sp) ||
> +                   (skb->dst->flags & DST_NOPOLICY) ||
> +                   __xfrm_policy_check(sk, dir, skb, family);
> +
> +#ifdef CONFIG_SECURITY_NETWORK
> +     if (ret)
> +             ret = security_skb_policy_check(skb, family);
> +#endif /* CONFIG_SECURITY_NETWORK */

Why is this code ifdef'd when the function is conditionally compiled?

> {
> +#ifdef CONFIG_SECURITY_NETWORK
> +     return security_skb_policy_check(skb, family);
> +#else
>       return 1;
> +#endif /* CONFIG_SECURITY_NETWORK */

Ditto.



-- 
James Morris
<[EMAIL PROTECTED]>
-
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to