Changeset View
Changeset View
Standalone View
Standalone View
src/test/test_bitcoin.cpp
Show All 35 Lines | |||||
void CConnmanTest::AddNode(CNode &node) { | void CConnmanTest::AddNode(CNode &node) { | ||||
LOCK(g_connman->cs_vNodes); | LOCK(g_connman->cs_vNodes); | ||||
g_connman->vNodes.push_back(&node); | g_connman->vNodes.push_back(&node); | ||||
} | } | ||||
void CConnmanTest::ClearNodes() { | void CConnmanTest::ClearNodes() { | ||||
LOCK(g_connman->cs_vNodes); | LOCK(g_connman->cs_vNodes); | ||||
for (CNode *node : g_connman->vNodes) { | |||||
delete node; | |||||
} | |||||
g_connman->vNodes.clear(); | g_connman->vNodes.clear(); | ||||
} | } | ||||
uint256 insecure_rand_seed = GetRandHash(); | uint256 insecure_rand_seed = GetRandHash(); | ||||
FastRandomContext insecure_rand_ctx(insecure_rand_seed); | FastRandomContext insecure_rand_ctx(insecure_rand_seed); | ||||
extern void noui_connect(); | extern void noui_connect(); | ||||
▲ Show 20 Lines • Show All 239 Lines • Show Last 20 Lines |