Skip to content

Commit

Permalink
ipv4: use skb_dst_copy() in ip_copy_metadata()
Browse files Browse the repository at this point in the history
Avoid touching dst refcount in ip_fragment().

Signed-off-by: Eric Dumazet <eric.dumazet@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
  • Loading branch information
Eric Dumazet authored and David S. Miller committed Jul 6, 2010
1 parent a99db19 commit fe76cda
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion net/ipv4/ip_output.c
Original file line number Diff line number Diff line change
Expand Up @@ -411,7 +411,7 @@ static void ip_copy_metadata(struct sk_buff *to, struct sk_buff *from)
to->priority = from->priority;
to->protocol = from->protocol;
skb_dst_drop(to);
skb_dst_set(to, dst_clone(skb_dst(from)));
skb_dst_copy(to, from);
to->dev = from->dev;
to->mark = from->mark;

Expand Down

0 comments on commit fe76cda

Please sign in to comment.