mirror of
https://github.com/twisterarmy/twister-core.git
synced 2025-01-10 23:07:52 +00:00
fix GetNextInMainChain (thanks Pieter Wuille for suggesting this)
This commit is contained in:
parent
b2a8e004ab
commit
1e1a23b5d8
@ -751,6 +751,7 @@ public:
|
||||
}
|
||||
|
||||
CBlockIndex *GetNextInMainChain() const {
|
||||
if( !IsInMainChain() ) return NULL;
|
||||
return nHeight+1 >= (int)vBlockIndexByHeight.size() ? NULL : vBlockIndexByHeight[nHeight+1];
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user