aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorAndrew Chow <achow101-github@achow101.com>2019-10-18 14:44:58 -0400
committerAndrew Chow <achow101-github@achow101.com>2021-09-29 16:48:43 -0400
commita00eb388e8046fe105666445dff6c91e8f8664cb (patch)
tree5823838efd17a1c85fb067014cd0b0e0c815d81a /src
parent419afa93419e6840f78cb94b4a39d826eb10e139 (diff)
downloadbitcoin-a00eb388e8046fe105666445dff6c91e8f8664cb.tar.xz
Allow CInputCoin to also be constructed with COutPoint and CTxOut
Diffstat (limited to 'src')
-rw-r--r--src/wallet/coinselection.h12
1 files changed, 12 insertions, 0 deletions
diff --git a/src/wallet/coinselection.h b/src/wallet/coinselection.h
index a28bee622e..78d877a10b 100644
--- a/src/wallet/coinselection.h
+++ b/src/wallet/coinselection.h
@@ -37,6 +37,18 @@ public:
m_input_bytes = input_bytes;
}
+ CInputCoin(const COutPoint& outpoint_in, const CTxOut& txout_in)
+ {
+ outpoint = outpoint_in;
+ txout = txout_in;
+ effective_value = txout.nValue;
+ }
+
+ CInputCoin(const COutPoint& outpoint_in, const CTxOut& txout_in, int input_bytes) : CInputCoin(outpoint_in, txout_in)
+ {
+ m_input_bytes = input_bytes;
+ }
+
COutPoint outpoint;
CTxOut txout;
CAmount effective_value;