Skip to content
  • Arnd Bergmann's avatar
    netfilter: nf_defrag: move NF_CONNTRACK bits into #ifdef · 41e4b391
    Arnd Bergmann authored
    We cannot access the skb->_nfct field when CONFIG_NF_CONNTRACK is
    disabled:
    
    net/ipv4/netfilter/nf_defrag_ipv4.c: In function 'ipv4_conntrack_defrag':
    net/ipv4/netfilter/nf_defrag_ipv4.c:83:9: error: 'struct sk_buff' has no member named '_nfct'
    net/ipv6/netfilter/nf_defrag_ipv6_hooks.c: In function 'ipv6_defrag':
    net/ipv6/netfilter/nf_defrag_ipv6_hooks.c:68:9: error: 'struct sk_buff' has no member named '_nfct'
    
    Both functions already have an #ifdef for this, so let's move the
    check in there.
    
    Fixes: 902d6a4c
    
     ("netfilter: nf_defrag: Skip defrag if NOTRACK is set")
    Signed-off-by: default avatarArnd Bergmann <arnd@arndb.de>
    Signed-off-by: default avatarPablo Neira Ayuso <pablo@netfilter.org>
    41e4b391