traceroute6: restore port after probing
authorDenys Vlasenko <vda.linux@googlemail.com>
Tue, 24 Nov 2009 13:10:06 +0000 (14:10 +0100)
committerDenys Vlasenko <vda.linux@googlemail.com>
Tue, 24 Nov 2009 13:10:06 +0000 (14:10 +0100)
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
networking/traceroute.c

index 0555c9b476fac9de937c34ef40e0943b372d5c8e..e9f3cc6c95a9947fbb2d10344e56cd77afe445a7 100644 (file)
@@ -1020,6 +1020,7 @@ common_traceroute_main(int op, char **argv)
                set_nport(dest_lsa, htons(1025));
                /* dummy connect. makes kernel pick source IP (and port) */
                xconnect(probe_fd, &dest_lsa->u.sa, dest_lsa->len);
+               set_nport(dest_lsa, htons(port));
 
                /* read IP and port */
                source_lsa = get_sock_lsa(probe_fd);