[Devel] [PATCH rh7] net: drop redandunt saddr assignment in ip_send_unicast_reply()

Konstantin Khorenko khorenko at virtuozzo.com
Mon Dec 18 18:09:57 MSK 2017


Revert "to review: net: provide proper saddr to flowi4_init_output()"

This is a leftover from the 2.6.32-x -> 3.10.0-x rebase.
After ms commit 70e7341673a4 ("ipv4: Show that ip_send_reply() is purely
unicast routine.") which adds "saddr" to ip_send_unicast_reply()
argument list we don't need to extract saddr from skb additionally.

Drop it.
No functonal changes as all calls to ip_send_unicast_reply()
provide same ip_hdr(skb)->daddr as "saddr" argument.

Signed-off-by: Konstantin Khorenko <khorenko at virtuozzo.com>
---
 net/ipv4/ip_output.c | 1 -
 1 file changed, 1 deletion(-)

diff --git a/net/ipv4/ip_output.c b/net/ipv4/ip_output.c
index c721c15..9fa4762 100644
--- a/net/ipv4/ip_output.c
+++ b/net/ipv4/ip_output.c
@@ -1565,7 +1565,6 @@ void ip_send_unicast_reply(struct sock *sk, struct sk_buff *skb,
 	if (__ip_options_echo(&replyopts.opt.opt, skb, sopt))
 		return;
 
-	saddr = ip_hdr(skb)->daddr;
 	ipc.addr = daddr;
 	ipc.opt = NULL;
 	ipc.tx_flags = 0;
-- 
2.1.4



More information about the Devel mailing list