diff --git a/src/avalanche/node.h b/src/avalanche/node.h --- a/src/avalanche/node.h +++ b/src/avalanche/node.h @@ -5,7 +5,7 @@ #ifndef BITCOIN_AVALANCHE_NODE_H #define BITCOIN_AVALANCHE_NODE_H -#include // For NodeId +#include #include #include diff --git a/src/avalanche/peermanager.h b/src/avalanche/peermanager.h --- a/src/avalanche/peermanager.h +++ b/src/avalanche/peermanager.h @@ -9,9 +9,9 @@ #include #include #include -#include #include #include +#include #include #include diff --git a/src/avalanche/processor.h b/src/avalanche/processor.h --- a/src/avalanche/processor.h +++ b/src/avalanche/processor.h @@ -27,9 +27,11 @@ #include class ArgsManager; -class Config; class CBlockIndex; +class CConnman; +class CNode; class CScheduler; +class Config; class PeerManager; struct bilingual_str; diff --git a/src/net.h b/src/net.h --- a/src/net.h +++ b/src/net.h @@ -18,6 +18,7 @@ #include #include #include +#include #include #include #include @@ -111,13 +112,6 @@ 1. - std::exp(-1. * AVALANCHE_STATISTICS_REFRESH_PERIOD.count() / AVALANCHE_STATISTICS_TIME_CONSTANT.count()); -typedef int64_t NodeId; - -/** - * Special NodeId that represent no node. - */ -static constexpr NodeId NO_NODE = -1; - struct AddedNodeInfo { std::string strAddedNode; CService resolvedAddress; diff --git a/src/nodeid.h b/src/nodeid.h new file mode 100644 --- /dev/null +++ b/src/nodeid.h @@ -0,0 +1,17 @@ +// Copyright (c) 2021 The Bitcoin developers +// Distributed under the MIT software license, see the accompanying +// file COPYING or http://www.opensource.org/licenses/mit-license.php. + +#ifndef BITCOIN_NODEID_H +#define BITCOIN_NODEID_H + +#include + +typedef int64_t NodeId; + +/** + * Special NodeId that represent no node. + */ +static constexpr NodeId NO_NODE = -1; + +#endif // BITCOIN_NODEID_H