Merge 950af7c876 into merged_master (Bitcoin PR bitcoin/bitcoin#28878)

This commit is contained in:
Byron Hambly 2025-11-10 14:27:35 +02:00
commit d46449ab86
No known key found for this signature in database
GPG key ID: DE8F6EA20A661697
36 changed files with 74 additions and 86 deletions

View file

@ -755,7 +755,7 @@ bool BlockManager::UndoWriteToDisk(const CBlockUndo& blockundo, FlatFilePos& pos
}
// Write index header
unsigned int nSize = GetSerializeSize(blockundo, CLIENT_VERSION);
unsigned int nSize = GetSerializeSize(blockundo);
fileout << GetParams().MessageStart() << nSize;
// Write undo data
@ -1071,7 +1071,7 @@ bool BlockManager::WriteUndoDataForBlock(const CBlockUndo& blockundo, BlockValid
// Write undo information to disk
if (block.GetUndoPos().IsNull()) {
FlatFilePos _pos;
if (!FindUndoPos(state, block.nFile, _pos, ::GetSerializeSize(blockundo, CLIENT_VERSION) + 40)) {
if (!FindUndoPos(state, block.nFile, _pos, ::GetSerializeSize(blockundo) + 40)) {
return error("ConnectBlock(): FindUndoPos failed");
}
if (!UndoWriteToDisk(blockundo, _pos, block.pprev->GetBlockHash())) {