diff options
author | Adam Ierymenko <adam.ierymenko@gmail.com> | 2014-03-31 22:23:55 -0700 |
---|---|---|
committer | Adam Ierymenko <adam.ierymenko@gmail.com> | 2014-03-31 22:23:55 -0700 |
commit | f13493edb2aae228ddbe70cc2f0609c541faf2d7 (patch) | |
tree | cb1a6845ec82e2ea361ce15e88440a249992091c /node/Switch.hpp | |
parent | 595b386afcd4e4eca0cf379cd14689c1db8ee647 (diff) | |
download | infinitytier-f13493edb2aae228ddbe70cc2f0609c541faf2d7.tar.gz infinitytier-f13493edb2aae228ddbe70cc2f0609c541faf2d7.zip |
Oops... turns out we need to differentiate incoming from outgoing TCP and indeed learn incoming TCP paths. Otherwise the recipient of a TCP connection does not know to reply via TCP! Heh.
Diffstat (limited to 'node/Switch.hpp')
-rw-r--r-- | node/Switch.hpp | 12 |
1 files changed, 5 insertions, 7 deletions
diff --git a/node/Switch.hpp b/node/Switch.hpp index fd5837b7..ee78d9fd 100644 --- a/node/Switch.hpp +++ b/node/Switch.hpp @@ -122,22 +122,20 @@ public: /** * Send a HELLO announcement immediately to the indicated address * - * @param fromSock Send from this local socket * @param dest Destination peer - * @param remoteAddr Remote address + * @param path Network path to peer * @return True if send appears successful */ - bool sendHELLO(const SharedPtr<Socket> &fromSock,const SharedPtr<Peer> &dest,const InetAddress &remoteAddr); + bool sendHELLO(const SharedPtr<Peer> &dest,const Path &path); /** - * Send a HELLO announcement immediately to the indicated address + * Send a HELLO announcement immediately to the indicated address via UDP * * @param dest Destination peer - * @param remoteAddr Remote address - * @param tcp Attempt to use TCP? + * @param destUdp UDP inet address * @return True if send appears successful */ - bool sendHELLO(const SharedPtr<Peer> &dest,const InetAddress &remoteAddr,bool tcp); + bool sendHELLO(const SharedPtr<Peer> &dest,const InetAddress &destUdp); /** * Send RENDEZVOUS to two peers to permit them to directly connect |