Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 6df59a84 authored by Steffen Klassert's avatar Steffen Klassert Committed by David S. Miller
Browse files

route: Take the right src and dst addresses in ip_route_newports



When we set up the flow informations in ip_route_newports(), we take
the address informations from the the rt_key_src and rt_key_dst fields
of the rtable. They appear to be empty. So take the address
informations from rt_src and rt_dst instead. This issue was introduced
by commit 5e2b61f7 ("ipv4: Remove
flowi from struct rtable.")

Signed-off-by: default avatarSteffen Klassert <steffen.klassert@secunet.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 37e826c5
Loading
Loading
Loading
Loading
+2 −2
Original line number Original line Diff line number Diff line
@@ -270,8 +270,8 @@ static inline struct rtable *ip_route_newports(struct rtable *rt,
		struct flowi4 fl4 = {
		struct flowi4 fl4 = {
			.flowi4_oif = rt->rt_oif,
			.flowi4_oif = rt->rt_oif,
			.flowi4_mark = rt->rt_mark,
			.flowi4_mark = rt->rt_mark,
			.daddr = rt->rt_key_dst,
			.daddr = rt->rt_dst,
			.saddr = rt->rt_key_src,
			.saddr = rt->rt_src,
			.flowi4_tos = rt->rt_tos,
			.flowi4_tos = rt->rt_tos,
			.flowi4_proto = protocol,
			.flowi4_proto = protocol,
			.fl4_sport = sport,
			.fl4_sport = sport,