diff options
author | Dwayne Boone <dwayne@zeroc.com> | 2007-06-13 14:04:24 -0230 |
---|---|---|
committer | Dwayne Boone <dwayne@zeroc.com> | 2007-06-13 14:04:24 -0230 |
commit | b2031b8795606b6893cb3766cc3f18f5c6c0c252 (patch) | |
tree | 79ad7a4f1c5e7866efc9547f1d4bb7354842579e /cpp/src/Ice/TcpConnector.cpp | |
parent | Merge branch 'master' of ssh://cvs.zeroc.com/home/git/ice (diff) | |
download | ice-b2031b8795606b6893cb3766cc3f18f5c6c0c252.tar.bz2 ice-b2031b8795606b6893cb3766cc3f18f5c6c0c252.tar.xz ice-b2031b8795606b6893cb3766cc3f18f5c6c0c252.zip |
Bug 1658 - fix collocation issue with endpoints listening on 0.0.0.0
Diffstat (limited to 'cpp/src/Ice/TcpConnector.cpp')
-rw-r--r-- | cpp/src/Ice/TcpConnector.cpp | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/cpp/src/Ice/TcpConnector.cpp b/cpp/src/Ice/TcpConnector.cpp index 312b6ed7e37..007824a952b 100644 --- a/cpp/src/Ice/TcpConnector.cpp +++ b/cpp/src/Ice/TcpConnector.cpp @@ -118,6 +118,14 @@ IceInternal::TcpConnector::operator<(const Connector& r) const return compareAddress(_addr, p->_addr) == -1; } +bool +IceInternal::TcpConnector::equivalent(const string& host, int port) const +{ + struct sockaddr_in addr; + getAddress(host, port, addr); + return compareAddress(addr, _addr) == 0; +} + IceInternal::TcpConnector::TcpConnector(const InstancePtr& instance, const struct sockaddr_in& addr, Ice::Int timeout, const string& connectionId) : _instance(instance), |