From cf095a53fcef8ad72e2f1177660ef50bc7e340ad Mon Sep 17 00:00:00 2001 From: Marcin Jachymiak Date: Thu, 17 Jan 2019 14:08:21 -0500 Subject: [PATCH 1/2] Move comment about BaseIndex::DB from TxIndex::DB --- src/index/base.h | 7 +++++++ src/index/txindex.cpp | 12 +++--------- 2 files changed, 10 insertions(+), 9 deletions(-) diff --git a/src/index/base.h b/src/index/base.h index 3fab810bb2..1063291480 100644 --- a/src/index/base.h +++ b/src/index/base.h @@ -21,6 +21,13 @@ class CBlockIndex; class BaseIndex : public CValidationInterface { protected: + /** + * The database stores a block locator of the chain the database is synced to + * so that the index can efficiently determine the point it last stopped at. + * A locator is used instead of a simple hash of the chain tip because blocks + * and block index entries may not be flushed to disk until after this database + * is updated. + */ class DB : public CDBWrapper { public: diff --git a/src/index/txindex.cpp b/src/index/txindex.cpp index 104b05d4ba..462ac5962f 100644 --- a/src/index/txindex.cpp +++ b/src/index/txindex.cpp @@ -16,15 +16,9 @@ constexpr char DB_TXINDEX_BLOCK = 'T'; std::unique_ptr g_txindex; -/** - * Access to the txindex database (indexes/txindex/) - * - * The database stores a block locator of the chain the database is synced to - * so that the TxIndex can efficiently determine the point it last stopped at. - * A locator is used instead of a simple hash of the chain tip because blocks - * and block index entries may not be flushed to disk until after this database - * is updated. - */ + + +/** Access to the txindex database (indexes/txindex/) */ class TxIndex::DB : public BaseIndex::DB { public: From 8ed2f1ed78937eff0bb8b5318a30da908e33af24 Mon Sep 17 00:00:00 2001 From: Marcin Jachymiak Date: Mon, 17 Aug 2020 09:57:43 -0400 Subject: [PATCH 2/2] Remove unused includes --- src/index/disktxpos.h | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/src/index/disktxpos.h b/src/index/disktxpos.h index 8cd2270028..69696b0ec5 100644 --- a/src/index/disktxpos.h +++ b/src/index/disktxpos.h @@ -5,10 +5,8 @@ #ifndef BITCOIN_INDEX_DISKTXPOS_H #define BITCOIN_INDEX_DISKTXPOS_H -#include #include -#include -#include +#include struct CDiskTxPos : public FlatFilePos {