Commit e023dd64 authored by Arnaldo Carvalho de Melo's avatar Arnaldo Carvalho de Melo Committed by David S. Miller

[IPMR]: Fix bug introduced when converting to skb_network_reset_header

Signed-off-by: default avatarArnaldo Carvalho de Melo <acme@redhat.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent c9bdd4b5
...@@ -1096,6 +1096,7 @@ static struct notifier_block ip_mr_notifier={ ...@@ -1096,6 +1096,7 @@ static struct notifier_block ip_mr_notifier={
static void ip_encap(struct sk_buff *skb, __be32 saddr, __be32 daddr) static void ip_encap(struct sk_buff *skb, __be32 saddr, __be32 daddr)
{ {
struct iphdr *iph; struct iphdr *iph;
struct iphdr *old_iph = skb->nh.iph;
skb_push(skb, sizeof(struct iphdr)); skb_push(skb, sizeof(struct iphdr));
skb->h.ipiph = skb->nh.iph; skb->h.ipiph = skb->nh.iph;
...@@ -1103,8 +1104,8 @@ static void ip_encap(struct sk_buff *skb, __be32 saddr, __be32 daddr) ...@@ -1103,8 +1104,8 @@ static void ip_encap(struct sk_buff *skb, __be32 saddr, __be32 daddr)
iph = skb->nh.iph; iph = skb->nh.iph;
iph->version = 4; iph->version = 4;
iph->tos = skb->nh.iph->tos; iph->tos = old_iph->tos;
iph->ttl = skb->nh.iph->ttl; iph->ttl = old_iph->ttl;
iph->frag_off = 0; iph->frag_off = 0;
iph->daddr = daddr; iph->daddr = daddr;
iph->saddr = saddr; iph->saddr = saddr;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment