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

Method BlockDisconnected

src/zmq/zmqnotificationinterface.cpp:176–189  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

174}
175
176void CZMQNotificationInterface::BlockDisconnected(const std::shared_ptr<const CBlock>& pblock, const CBlockIndex* pindexDisconnected)
177{
178 for (const CTransactionRef& ptx : pblock->vtx) {
179 const CTransaction& tx = *ptx;
180 TryForEachAndRemoveFailed(notifiers, [&tx](CZMQAbstractNotifier* notifier) {
181 return notifier->NotifyTransaction(tx);
182 });
183 }
184
185 // Next we notify BlockDisconnect listeners for *all* blocks
186 TryForEachAndRemoveFailed(notifiers, [pindexDisconnected](CZMQAbstractNotifier* notifier) {
187 return notifier->NotifyBlockDisconnect(pindexDisconnected);
188 });
189}
190
191CZMQNotificationInterface* g_zmq_notification_interface = nullptr;

Callers

nothing calls this directly

Calls 3

NotifyTransactionMethod · 0.45
NotifyBlockDisconnectMethod · 0.45

Tested by

no test coverage detected