[SK_BUFF]: Introduce ip_hdr(), remove skb->nh.iph
[pandora-kernel.git] / net / ipv4 / netfilter / ip_conntrack_standalone.c
index 56b2f75..c322001 100644 (file)
@@ -439,7 +439,7 @@ static unsigned int ip_conntrack_defrag(unsigned int hooknum,
 #endif
 
        /* Gather fragments. */
-       if ((*pskb)->nh.iph->frag_off & htons(IP_MF|IP_OFFSET)) {
+       if (ip_hdr(*pskb)->frag_off & htons(IP_MF | IP_OFFSET)) {
                *pskb = ip_ct_gather_frags(*pskb,
                                           hooknum == NF_IP_PRE_ROUTING ?
                                           IP_DEFRAG_CONNTRACK_IN :
@@ -458,7 +458,7 @@ static unsigned int ip_conntrack_local(unsigned int hooknum,
 {
        /* root is playing with raw sockets. */
        if ((*pskb)->len < sizeof(struct iphdr)
-           || (*pskb)->nh.iph->ihl * 4 < sizeof(struct iphdr)) {
+           || ip_hdrlen(*pskb) < sizeof(struct iphdr)) {
                if (net_ratelimit())
                        printk("ipt_hook: happy cracking.\n");
                return NF_ACCEPT;