mirror of
https://github.com/monero-project/monero.git
synced 2024-12-22 19:49:30 +00:00
rpc: fix comparison of seconds vs microseconds
This commit is contained in:
parent
25419b4bfb
commit
0569e635cf
1 changed files with 1 additions and 1 deletions
|
@ -366,7 +366,7 @@ namespace cryptonote
|
||||||
for (std::unordered_map<crypto::public_key, client_info>::iterator i = m_client_info.begin(); i != m_client_info.end(); )
|
for (std::unordered_map<crypto::public_key, client_info>::iterator i = m_client_info.begin(); i != m_client_info.end(); )
|
||||||
{
|
{
|
||||||
std::unordered_map<crypto::public_key, client_info>::iterator j = i++;
|
std::unordered_map<crypto::public_key, client_info>::iterator j = i++;
|
||||||
const time_t t = std::max(j->second.last_request_timestamp, j->second.update_time);
|
const time_t t = std::max(j->second.last_request_timestamp / 1000000, j->second.update_time);
|
||||||
const bool erase = t < ((j->second.credits == 0) ? threshold0 : threshold);
|
const bool erase = t < ((j->second.credits == 0) ? threshold0 : threshold);
|
||||||
if (erase)
|
if (erase)
|
||||||
{
|
{
|
||||||
|
|
Loading…
Reference in a new issue