]> bbs.cooldavid.org Git - net-next-2.6.git/blobdiff - net/ipv4/ipvs/ip_vs_app.c
[SK_BUFF]: Introduce skb_network_header()
[net-next-2.6.git] / net / ipv4 / ipvs / ip_vs_app.c
index 22e104c6a49387fafdd139f9ca1b07bd849fbc38..f29d3a27eec62cf7c0eaab0f05eb402ee99bb65d 100644 (file)
@@ -338,7 +338,7 @@ static inline int app_tcp_pkt_out(struct ip_vs_conn *cp, struct sk_buff **pskb,
        if (!ip_vs_make_skb_writable(pskb, tcp_offset + sizeof(*th)))
                return 0;
 
-       th = (struct tcphdr *)((*pskb)->nh.raw + tcp_offset);
+       th = (struct tcphdr *)(skb_network_header(*pskb) + tcp_offset);
 
        /*
         *      Remember seq number in case this pkt gets resized
@@ -413,7 +413,7 @@ static inline int app_tcp_pkt_in(struct ip_vs_conn *cp, struct sk_buff **pskb,
        if (!ip_vs_make_skb_writable(pskb, tcp_offset + sizeof(*th)))
                return 0;
 
-       th = (struct tcphdr *)((*pskb)->nh.raw + tcp_offset);
+       th = (struct tcphdr *)(skb_network_header(*pskb) + tcp_offset);
 
        /*
         *      Remember seq number in case this pkt gets resized