Browse Source

Add override to functions using CValidationInterface methods

0.15
Matt Corallo 8 years ago
parent
commit
acad82f375
  1. 8
      src/net_processing.h
  2. 2
      src/rpc/mining.cpp
  3. 8
      src/zmq/zmqnotificationinterface.h

8
src/net_processing.h

@ -30,10 +30,10 @@ private:
public: public:
PeerLogicValidation(CConnman* connmanIn); PeerLogicValidation(CConnman* connmanIn);
virtual void BlockConnected(const std::shared_ptr<const CBlock>& pblock, const CBlockIndex* pindexConnected, const std::vector<CTransactionRef>& vtxConflicted); void BlockConnected(const std::shared_ptr<const CBlock>& pblock, const CBlockIndex* pindexConnected, const std::vector<CTransactionRef>& vtxConflicted) override;
virtual void UpdatedBlockTip(const CBlockIndex *pindexNew, const CBlockIndex *pindexFork, bool fInitialDownload); void UpdatedBlockTip(const CBlockIndex *pindexNew, const CBlockIndex *pindexFork, bool fInitialDownload) override;
virtual void BlockChecked(const CBlock& block, const CValidationState& state); void BlockChecked(const CBlock& block, const CValidationState& state) override;
virtual void NewPoWValidBlock(const CBlockIndex *pindex, const std::shared_ptr<const CBlock>& pblock); void NewPoWValidBlock(const CBlockIndex *pindex, const std::shared_ptr<const CBlock>& pblock) override;
}; };
struct CNodeStateStats { struct CNodeStateStats {

2
src/rpc/mining.cpp

@ -710,7 +710,7 @@ public:
submitblock_StateCatcher(const uint256 &hashIn) : hash(hashIn), found(false), state() {} submitblock_StateCatcher(const uint256 &hashIn) : hash(hashIn), found(false), state() {}
protected: protected:
virtual void BlockChecked(const CBlock& block, const CValidationState& stateIn) { void BlockChecked(const CBlock& block, const CValidationState& stateIn) override {
if (block.GetHash() != hash) if (block.GetHash() != hash)
return; return;
found = true; found = true;

8
src/zmq/zmqnotificationinterface.h

@ -25,10 +25,10 @@ protected:
void Shutdown(); void Shutdown();
// CValidationInterface // CValidationInterface
void TransactionAddedToMempool(const CTransactionRef& tx); void TransactionAddedToMempool(const CTransactionRef& tx) override;
void BlockConnected(const std::shared_ptr<const CBlock>& pblock, const CBlockIndex* pindexConnected, const std::vector<CTransactionRef>& vtxConflicted); void BlockConnected(const std::shared_ptr<const CBlock>& pblock, const CBlockIndex* pindexConnected, const std::vector<CTransactionRef>& vtxConflicted) override;
void BlockDisconnected(const std::shared_ptr<const CBlock>& pblock); void BlockDisconnected(const std::shared_ptr<const CBlock>& pblock) override;
void UpdatedBlockTip(const CBlockIndex *pindexNew, const CBlockIndex *pindexFork, bool fInitialDownload); void UpdatedBlockTip(const CBlockIndex *pindexNew, const CBlockIndex *pindexFork, bool fInitialDownload) override;
private: private:
CZMQNotificationInterface(); CZMQNotificationInterface();

Loading…
Cancel
Save