From 21fd7cb071d236d61b9ec1c1896c71015932e07e Mon Sep 17 00:00:00 2001 From: Lionel Gauthier Date: Thu, 18 Dec 2014 13:17:27 +0000 Subject: [PATCH] git-svn-id: http://svn.eurecom.fr/openair4G/trunk@6284 818b1a75-f10b-46b9-bf7c-635c3b92a50f --- openair-cn/GTPV1-U/GTPURH/xt_GTPURH.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/openair-cn/GTPV1-U/GTPURH/xt_GTPURH.c b/openair-cn/GTPV1-U/GTPURH/xt_GTPURH.c index f1b7c1d532..28f1e22f41 100755 --- a/openair-cn/GTPV1-U/GTPURH/xt_GTPURH.c +++ b/openair-cn/GTPV1-U/GTPURH/xt_GTPURH.c @@ -403,14 +403,14 @@ _gtpurh_tg4_rem(struct sk_buff *orig_skb_pP, const struct xt_action_param *par_p } - skb_reserve(new_skb_p, LL_MAX_HEADER); + skb_reserve(new_skb_p, LL_MAX_HEADER + ntohs(iph2_p->tot_len)); new_skb_p->protocol = skb_p->protocol; - skb_reset_network_header(new_skb_p); - new_ip_p = (void *)skb_put(new_skb_p, iph2_p->ihl << 2); + new_ip_p = (void *)skb_push(new_skb_p, ntohs(iph2_p->tot_len) - (iph2_p->ihl << 2)); skb_reset_transport_header(new_skb_p); - skb_put(new_skb_p, ntohs(iph2_p->tot_len) - (iph2_p->ihl << 2)); + new_ip_p = (void *)skb_push(new_skb_p, iph2_p->ihl << 2); memcpy(new_ip_p, iph2_p, ntohs(iph2_p->tot_len)); + skb_reset_network_header(new_skb_p); new_skb_p->mark = ntohl(gtpuh_p->tunid); //new_skb_p->mark = skb_p->mark;