Update BoostConnection.h
This commit is contained in:
parent
b379f21cb3
commit
f4bd7c1ca3
1 changed files with 4 additions and 2 deletions
|
@ -57,8 +57,10 @@ public:
|
||||||
boost::asio::ip::tcp::resolver::iterator endpointIterator)
|
boost::asio::ip::tcp::resolver::iterator endpointIterator)
|
||||||
{
|
{
|
||||||
if (!error) {
|
if (!error) {
|
||||||
|
#ifdef APP_DEBUG
|
||||||
boost::asio::ip::tcp::endpoint endpoint = *endpointIterator;
|
boost::asio::ip::tcp::endpoint endpoint = *endpointIterator;
|
||||||
|
#endif
|
||||||
|
|
||||||
LOG_DEBUG("[%s:%d] DNS resolved ", endpoint.address().to_string().c_str(), endpoint.port());
|
LOG_DEBUG("[%s:%d] DNS resolved ", endpoint.address().to_string().c_str(), endpoint.port());
|
||||||
m_socket.connect(endpointIterator, boost::bind(&BoostConnection::handleConnect, this->shared_from_this(),
|
m_socket.connect(endpointIterator, boost::bind(&BoostConnection::handleConnect, this->shared_from_this(),
|
||||||
boost::asio::placeholders::error));
|
boost::asio::placeholders::error));
|
||||||
|
@ -159,4 +161,4 @@ private:
|
||||||
char receiveBuffer_[2048];
|
char receiveBuffer_[2048];
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif /* __BOOSTCONNECTION_H__ */
|
#endif /* __BOOSTCONNECTION_H__ */
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue