removed floating point operation in rate limited udp socket
This commit is contained in:
parent
bbb551eb8e
commit
deb363e53b
|
@ -717,7 +717,7 @@ void rate_limited_udp_socket::on_tick(error_code const& e)
|
|||
|
||||
time_duration delta = now - m_last_tick;
|
||||
m_last_tick = now;
|
||||
if (m_quota < m_rate_limit) m_quota += m_rate_limit * total_milliseconds(delta) / 1000.f;
|
||||
if (m_quota < m_rate_limit) m_quota += m_rate_limit * total_milliseconds(delta) / 1000;
|
||||
|
||||
if (m_queue.empty()) return;
|
||||
|
||||
|
|
Loading…
Reference in New Issue