Skip to content

Commit

Permalink
Move comment about BaseIndex::DB from TxIndex::DB
Browse files Browse the repository at this point in the history
  • Loading branch information
marcinja committed Aug 19, 2020
1 parent a2a250c commit cf095a5
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 9 deletions.
7 changes: 7 additions & 0 deletions src/index/base.h
Original file line number Diff line number Diff line change
Expand Up @@ -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:
Expand Down
12 changes: 3 additions & 9 deletions src/index/txindex.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -16,15 +16,9 @@ constexpr char DB_TXINDEX_BLOCK = 'T';

std::unique_ptr<TxIndex> 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:
Expand Down

0 comments on commit cf095a5

Please sign in to comment.