LKML Archive on
help / color / mirror / Atom feed
From: David Miller <>
Subject: Re: [net-next] ipv6: sr: Extract the right key values for "seg6_make_flowlabel"
Date: Fri, 27 Apr 2018 13:59:07 -0400 (EDT)	[thread overview]
Message-ID: <> (raw)
In-Reply-To: <>

From: Ahmed Abdelsalam <>
Date: Thu, 26 Apr 2018 16:11:11 +0200

> @@ -119,6 +119,9 @@ int seg6_do_srh_encap(struct sk_buff *skb, struct ipv6_sr_hdr *osrh, int proto)
>  	int hdrlen, tot_len, err;
>  	__be32 flowlabel;
> +	inner_hdr = ipv6_hdr(skb);

You have to make this assignment after, not before, the skb_cow_header()
call.  Otherwise this point can be pointing to freed up memory.

  reply	other threads:[~2018-04-27 17:59 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-04-26 14:11 Ahmed Abdelsalam
2018-04-27 17:59 ` David Miller [this message]
2018-04-28 10:20   ` Ahmed Abdelsalam

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \ \ \ \ \ \ \
    --subject='Re: [net-next] ipv6: sr: Extract the right key values for "seg6_make_flowlabel"' \

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).