diff options
Diffstat (limited to 'src/syncServer.cpp')
-rw-r--r-- | src/syncServer.cpp | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/syncServer.cpp b/src/syncServer.cpp index b61872c..ecf9fb4 100644 --- a/src/syncServer.cpp +++ b/src/syncServer.cpp @@ -42,8 +42,10 @@ SyncServer::SyncServer(std::string localaddr, std::string port, ConnectCallback gResolver.resolveTcp(localaddr, port, boost::bind(&SyncServer::onResolve, this, _1), boost::bind(&SyncServer::onResolvError, this, _1)); } -void SyncServer::onResolve(const SyncTcpConnection::proto::endpoint& e) +void SyncServer::onResolve(const SyncTcpConnection::proto::resolver::iterator& it) { + SyncTcpConnection::proto::endpoint e = *it; + acceptor_.open(e.protocol()); acceptor_.set_option(boost::asio::socket_base::reuse_address(true)); acceptor_.bind(e); |