Commit 25f111f2 authored by Shmulik Ladkani's avatar Shmulik Ladkani Committed by Greg Kroah-Hartman

ipv6: sr: properly initialize flowi6 prior passing to ip6_route_output

[ Upstream commit 1b4e5ad5 ]

In 'seg6_output', stack variable 'struct flowi6 fl6' was missing
initialization.

Fixes: 6c8702c6 ("ipv6: sr: add support for SRH encapsulation and injection with lwtunnels")
Signed-off-by: default avatarShmulik Ladkani <shmulik.ladkani@gmail.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 9380dc7c
...@@ -327,6 +327,7 @@ static int seg6_output(struct net *net, struct sock *sk, struct sk_buff *skb) ...@@ -327,6 +327,7 @@ static int seg6_output(struct net *net, struct sock *sk, struct sk_buff *skb)
struct ipv6hdr *hdr = ipv6_hdr(skb); struct ipv6hdr *hdr = ipv6_hdr(skb);
struct flowi6 fl6; struct flowi6 fl6;
memset(&fl6, 0, sizeof(fl6));
fl6.daddr = hdr->daddr; fl6.daddr = hdr->daddr;
fl6.saddr = hdr->saddr; fl6.saddr = hdr->saddr;
fl6.flowlabel = ip6_flowinfo(hdr); fl6.flowlabel = ip6_flowinfo(hdr);
......
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