mirror of
https://github.com/bitcoin/bitcoin.git
synced 2025-06-29 10:19:26 +02:00
refactor: VectorWriter without nVersion
The field is unused, so remove it. This is also required for future commits.
This commit is contained in:
@ -316,7 +316,7 @@ struct PSBTInput
|
||||
const auto& [leaf_hashes, origin] = leaf_origin;
|
||||
SerializeToVector(s, PSBT_IN_TAP_BIP32_DERIVATION, xonly);
|
||||
std::vector<unsigned char> value;
|
||||
CVectorWriter s_value{s.GetVersion(), value, 0};
|
||||
VectorWriter s_value{value, 0};
|
||||
s_value << leaf_hashes;
|
||||
SerializeKeyOrigin(s_value, origin);
|
||||
s << value;
|
||||
@ -757,7 +757,7 @@ struct PSBTOutput
|
||||
if (!m_tap_tree.empty()) {
|
||||
SerializeToVector(s, PSBT_OUT_TAP_TREE);
|
||||
std::vector<unsigned char> value;
|
||||
CVectorWriter s_value{s.GetVersion(), value, 0};
|
||||
VectorWriter s_value{value, 0};
|
||||
for (const auto& [depth, leaf_ver, script] : m_tap_tree) {
|
||||
s_value << depth;
|
||||
s_value << leaf_ver;
|
||||
@ -771,7 +771,7 @@ struct PSBTOutput
|
||||
const auto& [leaf_hashes, origin] = leaf;
|
||||
SerializeToVector(s, PSBT_OUT_TAP_BIP32_DERIVATION, xonly);
|
||||
std::vector<unsigned char> value;
|
||||
CVectorWriter s_value{s.GetVersion(), value, 0};
|
||||
VectorWriter s_value{value, 0};
|
||||
s_value << leaf_hashes;
|
||||
SerializeKeyOrigin(s_value, origin);
|
||||
s << value;
|
||||
|
Reference in New Issue
Block a user