From fc747ef4a649cd90aec5193a8af6b7accb5eb03f Mon Sep 17 00:00:00 2001 From: Felix Lange Date: Sat, 18 Apr 2015 01:50:31 +0200 Subject: p2p/discover: new endpoint format This commit changes the discovery protocol to use the new "v4" endpoint format, which allows for separate UDP and TCP ports and makes it possible to discover the UDP address after NAT. --- p2p/server_test.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'p2p/server_test.go') diff --git a/p2p/server_test.go b/p2p/server_test.go index 53cc3c258..86514b650 100644 --- a/p2p/server_test.go +++ b/p2p/server_test.go @@ -102,7 +102,7 @@ func TestServerDial(t *testing.T) { // tell the server to connect tcpAddr := listener.Addr().(*net.TCPAddr) - srv.SuggestPeer(&discover.Node{IP: tcpAddr.IP, TCPPort: tcpAddr.Port}) + srv.SuggestPeer(&discover.Node{IP: tcpAddr.IP, TCP: uint16(tcpAddr.Port)}) select { case conn := <-accepted: -- cgit v1.2.3