diff options
author | Ava Chow <github@achow101.com> | 2024-01-26 15:27:13 -0500 |
---|---|---|
committer | Ava Chow <github@achow101.com> | 2024-06-07 13:55:23 -0400 |
commit | 429ec1aaaaafab150f11e27fcf132a99b57c4fc7 (patch) | |
tree | e09999b341f124bf12712f5111d563a9003f1872 /src/rpc/rawtransaction.cpp | |
parent | 27e70f1f5be1f536f2314cd2ea42b4f80d927fbd (diff) | |
download | bitcoin-429ec1aaaaafab150f11e27fcf132a99b57c4fc7.tar.xz |
refactor: Rename CTransaction::nVersion to version
In order to ensure that the change of nVersion to a uint32_t in the
previous commit has no effect, rename nVersion to version in this commit
so that reviewers can easily spot if a spot was missed or if there is a
check somewhere whose semantics have changed.
Diffstat (limited to 'src/rpc/rawtransaction.cpp')
-rw-r--r-- | src/rpc/rawtransaction.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/rpc/rawtransaction.cpp b/src/rpc/rawtransaction.cpp index 012da77f54..f45c921c3c 100644 --- a/src/rpc/rawtransaction.cpp +++ b/src/rpc/rawtransaction.cpp @@ -1748,8 +1748,8 @@ static RPCHelpMan joinpsbts() } psbtxs.push_back(psbtx); // Choose the highest version number - if (psbtx.tx->nVersion > best_version) { - best_version = psbtx.tx->nVersion; + if (psbtx.tx->version > best_version) { + best_version = psbtx.tx->version; } // Choose the lowest lock time if (psbtx.tx->nLockTime < best_locktime) { @@ -1760,7 +1760,7 @@ static RPCHelpMan joinpsbts() // Create a blank psbt where everything will be added PartiallySignedTransaction merged_psbt; merged_psbt.tx = CMutableTransaction(); - merged_psbt.tx->nVersion = best_version; + merged_psbt.tx->version = best_version; merged_psbt.tx->nLockTime = best_locktime; // Merge @@ -1795,7 +1795,7 @@ static RPCHelpMan joinpsbts() PartiallySignedTransaction shuffled_psbt; shuffled_psbt.tx = CMutableTransaction(); - shuffled_psbt.tx->nVersion = merged_psbt.tx->nVersion; + shuffled_psbt.tx->version = merged_psbt.tx->version; shuffled_psbt.tx->nLockTime = merged_psbt.tx->nLockTime; for (int i : input_indices) { shuffled_psbt.AddInput(merged_psbt.tx->vin[i], merged_psbt.inputs[i]); |