mirror of
https://github.com/bitcoin/bitcoin.git
synced 2025-11-12 23:18:14 +01:00
Merge bitcoin/bitcoin#28878: Remove version field from GetSerializeSize
83986f464cInclude version.h in fewer places (Anthony Towns)c7b61fd61bConvert some CDataStream to DataStream (Anthony Towns)1410d300dfserialize: Drop useless version param from GetSerializeSize() (Anthony Towns)bf574a7501serialize: drop GetSerializeSizeMany (Anthony Towns)efa9eb6d7cserialize: Drop nVersion from [C]SizeComputer (Anthony Towns) Pull request description: Drops the version field from `GetSerializeSize()`, simplifying the code in various places. Also drop `GetSerializeSizeMany()` (as just removing the version parameter could result in silent bugs) and remove unnecessary instances of `#include <version.h>`. ACKs for top commit: maflcko: ACK83986f464c📒 theuni: ACK83986f464c. Tree-SHA512: 36617b6dfbb1b4b0afbf673e905525fc6d623d3f568d3f86e3b9d4f69820db97d099e83a88007bfff881f731ddca6755ebf1549e8d8a7762437dfadbf434c62e
This commit is contained in:
@@ -1121,7 +1121,7 @@ void TestNode(const MsCtx script_ctx, const NodeRef& node, FuzzedDataProvider& p
|
||||
assert(mal_success);
|
||||
assert(stack_nonmal == stack_mal);
|
||||
// Compute witness size (excluding script push, control block, and witness count encoding).
|
||||
const size_t wit_size = GetSerializeSize(stack_nonmal, PROTOCOL_VERSION) - GetSizeOfCompactSize(stack_nonmal.size());
|
||||
const size_t wit_size = GetSerializeSize(stack_nonmal) - GetSizeOfCompactSize(stack_nonmal.size());
|
||||
assert(wit_size <= *node->GetWitnessSize());
|
||||
|
||||
// Test non-malleable satisfaction.
|
||||
|
||||
Reference in New Issue
Block a user