Skip to content

Commit

Permalink
[Trivial] rename DisconnectBlocks argument for consistency
Browse files Browse the repository at this point in the history
  • Loading branch information
random-zebra committed Sep 23, 2019
1 parent 3df34c6 commit faa9090
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
6 changes: 3 additions & 3 deletions src/main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3756,14 +3756,14 @@ bool static ConnectTip(CValidationState& state, CBlockIndex* pindexNew, CBlock*
return true;
}

bool DisconnectBlocks(int blocks)
bool DisconnectBlocks(int nBlocks)
{
LOCK(cs_main);

CValidationState state;

LogPrintf("%s: Got command to replay %d blocks\n", __func__, blocks);
for (int i = 0; i <= blocks; i++)
LogPrintf("%s: Got command to replay %d blocks\n", __func__, nBlocks);
for (int i = 0; i <= nBlocks; i++)
DisconnectTip(state);

return true;
Expand Down
2 changes: 1 addition & 1 deletion src/main.h
Original file line number Diff line number Diff line change
Expand Up @@ -461,7 +461,7 @@ bool ReadBlockFromDisk(CBlock& block, const CBlockIndex* pindex);
bool DisconnectBlock(CBlock& block, CValidationState& state, CBlockIndex* pindex, CCoinsViewCache& coins, bool* pfClean = NULL);

/** Reprocess a number of blocks to try and get on the correct chain again **/
bool DisconnectBlocks(int blocks);
bool DisconnectBlocks(int nBlocks);
void ReprocessBlocks(int nBlocks);

/** Apply the effects of this block (with given index) on the UTXO set represented by coins */
Expand Down

0 comments on commit faa9090

Please sign in to comment.