net: make CNode's id private

pull/365/head
Cory Fields 8 years ago
parent 9ff0a51164
commit 0f3471f3ad

@ -2623,10 +2623,10 @@ CNode::CNode(NodeId idIn, ServiceFlags nLocalServicesIn, int nMyStartingHeightIn
nTimeConnected(GetSystemTimeInSeconds()), nTimeConnected(GetSystemTimeInSeconds()),
addr(addrIn), addr(addrIn),
fInbound(fInboundIn), fInbound(fInboundIn),
id(idIn),
nKeyedNetGroup(nKeyedNetGroupIn), nKeyedNetGroup(nKeyedNetGroupIn),
addrKnown(5000, 0.001), addrKnown(5000, 0.001),
filterInventoryKnown(50000, 0.000001), filterInventoryKnown(50000, 0.000001),
id(idIn),
nLocalHostNonce(nLocalHostNonceIn), nLocalHostNonce(nLocalHostNonceIn),
nLocalServices(nLocalServicesIn), nLocalServices(nLocalServicesIn),
nMyStartingHeight(nMyStartingHeightIn), nMyStartingHeight(nMyStartingHeightIn),

@ -611,7 +611,6 @@ public:
CCriticalSection cs_filter; CCriticalSection cs_filter;
CBloomFilter* pfilter; CBloomFilter* pfilter;
std::atomic<int> nRefCount; std::atomic<int> nRefCount;
const NodeId id;
const uint64_t nKeyedNetGroup; const uint64_t nKeyedNetGroup;
std::atomic_bool fPauseRecv; std::atomic_bool fPauseRecv;
@ -682,6 +681,7 @@ public:
private: private:
CNode(const CNode&); CNode(const CNode&);
void operator=(const CNode&); void operator=(const CNode&);
const NodeId id;
const uint64_t nLocalHostNonce; const uint64_t nLocalHostNonce;

Loading…
Cancel
Save