aboutsummaryrefslogtreecommitdiff
path: root/src/rpc/net.cpp
diff options
context:
space:
mode:
authorfanquake <fanquake@gmail.com>2020-10-24 19:13:42 +0800
committerfanquake <fanquake@gmail.com>2020-12-13 11:41:33 +0800
commit0475c8ba4d10dce79092361bc4c23c11dadba39a (patch)
tree621d4ded7bbd1bd742fc93a0f914166765890d72 /src/rpc/net.cpp
parentf805933e70d4320e62739f4cecfc08bdbad8afaa (diff)
downloadbitcoin-0475c8ba4d10dce79092361bc4c23c11dadba39a.tar.xz
net: use std::chrono throughout maxOutbound logic
Diffstat (limited to 'src/rpc/net.cpp')
-rw-r--r--src/rpc/net.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/rpc/net.cpp b/src/rpc/net.cpp
index 973d730218..6a2d1ea77f 100644
--- a/src/rpc/net.cpp
+++ b/src/rpc/net.cpp
@@ -487,12 +487,12 @@ static RPCHelpMan getnettotals()
obj.pushKV("timemillis", GetTimeMillis());
UniValue outboundLimit(UniValue::VOBJ);
- outboundLimit.pushKV("timeframe", node.connman->GetMaxOutboundTimeframe());
+ outboundLimit.pushKV("timeframe", count_seconds(node.connman->GetMaxOutboundTimeframe()));
outboundLimit.pushKV("target", node.connman->GetMaxOutboundTarget());
outboundLimit.pushKV("target_reached", node.connman->OutboundTargetReached(false));
outboundLimit.pushKV("serve_historical_blocks", !node.connman->OutboundTargetReached(true));
outboundLimit.pushKV("bytes_left_in_cycle", node.connman->GetOutboundTargetBytesLeft());
- outboundLimit.pushKV("time_left_in_cycle", node.connman->GetMaxOutboundTimeLeftInCycle());
+ outboundLimit.pushKV("time_left_in_cycle", count_seconds(node.connman->GetMaxOutboundTimeLeftInCycle()));
obj.pushKV("uploadtarget", outboundLimit);
return obj;
},