This is to track the regression introduced in master, which needs fixing for 0.14. See #9240, #9371, etc.
int nLastBlockFile = 0;
    /** Global flag to indicate we should check to see if there are
     *  block/undo files that should be deleted.  Set on startup
     *  or if we allocate more file space when we're in prune mode
     */
    bool fCheckForPruning = false;
    /**
     * Every received block is assigned a unique and increasing identifier, so we
     * know which one to give priority in case of a fork.
     */
    CCriticalSection cs_nBlockSequenceId;
    
    int32_t nBlockSequenceId = 1;
    
    int32_t nBlockReverseSequenceId = -1;
    
    arith_uint256 nLastPreciousChainwork = 0;
    
    set<CBlockIndex*> setDirtyBlockIndex;
    
    set<int> setDirtyFileInfo;
} 
/* Use this class to start tracking transactions that are removed from the
 * mempool and pass all those transactions through SyncTransaction when the
 * object goes out of scope. This is currently only used to call SyncTransaction
 * on conflicts removed from the mempool during block connection.  Applied in
 * ActivateBestChain around ActivateBestStep which in turn calls:
 * ConnectTip->removeForBlock->removeConflicts
 */
class MemPoolConflictRemovalTracker