Skip to content

Commit 5b57be8

Browse files
committed
fix: parse full chain index when maxBlockNum=0
Makes behavior consistent with the disk-based parser, i.e. to parse the full chain up to the maximum height when setting maxBlockNum to 0
1 parent cd99c5e commit 5b57be8

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

tools/parser/chain_index.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -194,7 +194,7 @@ void ChainIndex<RPCTag>::update(const ConfigType &config, blocksci::BlockHeight
194194

195195

196196
auto maxBlockHeight = static_cast<blocksci::BlockHeight>(bapi.getblockcount());
197-
if (blockHeight < 0) {
197+
if (blockHeight <= 0) {
198198
blockHeight = maxBlockHeight + blockHeight;
199199
}
200200
if (blockHeight > maxBlockHeight) {

0 commit comments

Comments
 (0)