diff --git a/misc/sim/treesim.go b/misc/sim/treesim.go index 8ea0659..d885926 100644 --- a/misc/sim/treesim.go +++ b/misc/sim/treesim.go @@ -379,12 +379,12 @@ func dumpDHTSize(store map[[32]byte]*Node) { fmt.Printf("DHT min %d / avg %f / max %d\n", min, avg, max) } -func (n *Node) startUDP(listen string) { - n.core.DEBUG_setupAndStartGlobalUDPInterface(listen) +func (n *Node) startTCP(listen string) { + n.core.DEBUG_setupAndStartGlobalTCPInterface(listen) } -func (n *Node) connectUDP(remoteAddr string) { - n.core.DEBUG_maybeSendUDPKeys(remoteAddr) +func (n *Node) connectTCP(remoteAddr string) { + n.core.AddPeer(remoteAddr) } //////////////////////////////////////////////////////////////////////////////// @@ -440,8 +440,8 @@ func main() { if false { // This connects the sim to the local network for _, node := range kstore { - node.startUDP("localhost:0") - node.connectUDP("localhost:12345") + node.startTCP("localhost:0") + node.connectTCP("localhost:12345") break // just 1 } for _, node := range kstore { diff --git a/src/yggdrasil/search.go b/src/yggdrasil/search.go index 593e7a2..4b9cd03 100644 --- a/src/yggdrasil/search.go +++ b/src/yggdrasil/search.go @@ -169,4 +169,3 @@ func (s *searches) checkDHTRes(info *searchInfo, res *dhtRes) bool { delete(s.searches, res.Dest) return true } - diff --git a/src/yggdrasil/wire.go b/src/yggdrasil/wire.go index 512a75c..6b592e5 100644 --- a/src/yggdrasil/wire.go +++ b/src/yggdrasil/wire.go @@ -511,4 +511,3 @@ func (r *dhtRes) decode(bs []byte) bool { } return true } -