|
|
@ -2454,8 +2454,11 @@ bool FindBlockPos(CValidationState &state, CDiskBlockPos &pos, unsigned int nAdd |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
nLastBlockFile = nFile; |
|
|
|
nLastBlockFile = nFile; |
|
|
|
vinfoBlockFile[nFile].nSize += nAddSize; |
|
|
|
|
|
|
|
vinfoBlockFile[nFile].AddBlock(nHeight, nTime); |
|
|
|
vinfoBlockFile[nFile].AddBlock(nHeight, nTime); |
|
|
|
|
|
|
|
if (fKnown) |
|
|
|
|
|
|
|
vinfoBlockFile[nFile].nSize = std::max(pos.nPos + nAddSize, vinfoBlockFile[nFile].nSize); |
|
|
|
|
|
|
|
else |
|
|
|
|
|
|
|
vinfoBlockFile[nFile].nSize += nAddSize; |
|
|
|
|
|
|
|
|
|
|
|
if (!fKnown) { |
|
|
|
if (!fKnown) { |
|
|
|
unsigned int nOldChunks = (pos.nPos + BLOCKFILE_CHUNK_SIZE - 1) / BLOCKFILE_CHUNK_SIZE; |
|
|
|
unsigned int nOldChunks = (pos.nPos + BLOCKFILE_CHUNK_SIZE - 1) / BLOCKFILE_CHUNK_SIZE; |
|
|
|