mirror of
https://github.com/PurpleI2P/i2pd.git
synced 2026-05-24 19:05:31 +00:00
Replace deadline_timer by steady_timer
Prevent deprecation warnings when building.
This commit is contained in:
@@ -123,7 +123,7 @@ namespace client
|
||||
// start UDP cleanup
|
||||
if (!m_ServerForwards.empty ())
|
||||
{
|
||||
m_CleanupUDPTimer.reset (new boost::asio::deadline_timer(m_SharedLocalDestination->GetService ()));
|
||||
m_CleanupUDPTimer.reset (new boost::asio::steady_timer(m_SharedLocalDestination->GetService ()));
|
||||
ScheduleCleanupUDP();
|
||||
}
|
||||
}
|
||||
@@ -1043,7 +1043,7 @@ namespace client
|
||||
if (m_CleanupUDPTimer)
|
||||
{
|
||||
// schedule cleanup in 17 seconds
|
||||
m_CleanupUDPTimer->expires_from_now (boost::posix_time::seconds (17));
|
||||
m_CleanupUDPTimer->expires_after (std::chrono::seconds (17));
|
||||
m_CleanupUDPTimer->async_wait(std::bind(&ClientContext::CleanupUDP, this, std::placeholders::_1));
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user