diff options
author | fanquake <fanquake@gmail.com> | 2021-03-04 20:00:06 +0800 |
---|---|---|
committer | fanquake <fanquake@gmail.com> | 2021-03-04 20:13:43 +0800 |
commit | 33921379b6bb989c9708867fedea1352a8091aa5 (patch) | |
tree | 57e0e7c1fa7e998a2610f1bc70ee78c8557b0d69 /src/net_processing.h | |
parent | 92b7efcf54d3154e4b31c9a6eae60f27e349f45e (diff) | |
parent | 0eaea66e8bfdfb23ff86c0f0924c2d75f5aca75f (diff) | |
download | bitcoin-33921379b6bb989c9708867fedea1352a8091aa5.tar.xz |
Merge #21015: Make all of net_processing (and some of net) use std::chrono types
0eaea66e8bfdfb23ff86c0f0924c2d75f5aca75f Make tx relay data structure use std::chrono types (Pieter Wuille)
55e82881a1503bff146970856c1474a6ea659c94 Make all Poisson delays use std::chrono types (Pieter Wuille)
c733ac4d8a597b1001555b142f488ed9fbecc405 Convert block/header sync timeouts to std::chrono types (Pieter Wuille)
4d98b401fbd821700f7a792b0a4cb52c9b71bc9f Change all ping times to std::chrono types (Pieter Wuille)
Pull request description:
(Picking up #20044. Rebased against master.)
This changes various uses of integers to represent timestamps and durations to `std::chrono` duration types with type-safe conversions, getting rid of various `.count()`, constructors, and conversion factors.
ACKs for top commit:
jnewbery:
utACK 0eaea66e8bfdfb23ff86c0f0924c2d75f5aca75f
vasild:
ACK 0eaea66e8bfdfb23ff86c0f0924c2d75f5aca75f
MarcoFalke:
re-ACK 0eaea66e8bfdfb23ff86c0f0924c2d75f5aca75f, only changes: minor rename, using C++11 member initializer, using 2min chrono literal, rebase 🤚
ajtowns:
utACK 0eaea66e8bfdfb23ff86c0f0924c2d75f5aca75f
Tree-SHA512: 2dbd8d53bf82e98f9b4611e61dc14c448e8957d1a02575b837fadfd59f80e98614d0ccf890fc351f960ade76a6fb8051b282e252e81675a8ee753dba8b1d7f57
Diffstat (limited to 'src/net_processing.h')
-rw-r--r-- | src/net_processing.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/net_processing.h b/src/net_processing.h index 3b09907443..6f900410a7 100644 --- a/src/net_processing.h +++ b/src/net_processing.h @@ -29,7 +29,7 @@ struct CNodeStateStats { int nSyncHeight = -1; int nCommonHeight = -1; int m_starting_height = -1; - int64_t m_ping_wait_usec; + std::chrono::microseconds m_ping_wait; std::vector<int> vHeightInFlight; }; |