fix issue with comparison of cached time and real-time (#719)

This commit is contained in:
Arvid Norberg 2016-05-09 08:21:00 -04:00
parent 5bedf3e7b3
commit 4057aa0391
1 changed files with 2 additions and 2 deletions

View File

@ -412,7 +412,7 @@ namespace libtorrent
m_socket->async_connect(m_remote m_socket->async_connect(m_remote
, boost::bind(&peer_connection::on_connection_complete, self(), _1)); , boost::bind(&peer_connection::on_connection_complete, self(), _1));
m_connect = clock_type::now(); m_connect = aux::time_now();
sent_syn(m_remote.address().is_v6()); sent_syn(m_remote.address().is_v6());
@ -4099,7 +4099,7 @@ namespace libtorrent
, boost::asio::error::get_misc_category()) , boost::asio::error::get_misc_category())
&& !in_handshake() && !in_handshake()
&& !is_connecting() && !is_connecting()
&& clock_type::now() - connected_time() < seconds(15)) && aux::time_now() - connected_time() < seconds(15))
{ {
peer_log(peer_log_alert::info, "SHORT_LIVED_DISCONNECT", ""); peer_log(peer_log_alert::info, "SHORT_LIVED_DISCONNECT", "");
} }