MCPcopy Create free account
hub / github.com/ElementsProject/elements / UpdateLastBlockAnnounceTime

Function UpdateLastBlockAnnounceTime

src/net_processing.cpp:1191–1196  ·  view source on GitHub ↗

This function is used for testing the stale tip eviction logic, see denialofservice_tests.cpp

Source from the content-addressed store, hash-verified

1189// This function is used for testing the stale tip eviction logic, see
1190// denialofservice_tests.cpp
1191void UpdateLastBlockAnnounceTime(NodeId node, int64_t time_in_seconds)
1192{
1193 LOCK(cs_main);
1194 CNodeState *state = State(node);
1195 if (state) state->m_last_block_announcement = time_in_seconds;
1196}
1197
1198void PeerManagerImpl::InitializeNode(const CNode *pnode)
1199{

Callers 1

BOOST_AUTO_TEST_CASEFunction · 0.85

Calls 1

StateEnum · 0.70

Tested by 1

BOOST_AUTO_TEST_CASEFunction · 0.68