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

Function RPCNotifyBlockChange

src/rpc/blockchain.cpp:333–341  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

331}
332
333void RPCNotifyBlockChange(const CBlockIndex* pindex)
334{
335 if(pindex) {
336 LOCK(cs_blockchange);
337 latestblock.hash = pindex->GetBlockHash();
338 latestblock.height = pindex->nHeight;
339 }
340 cond_blockchange.notify_all();
341}
342
343static RPCHelpMan waitfornewblock()
344{

Callers 2

OnRPCStoppedFunction · 0.85
AppInitMainFunction · 0.85

Calls 1

GetBlockHashMethod · 0.45

Tested by

no test coverage detected