Use the correct empty memo for Sapling outputs
This commit is contained in:
parent
bcdb4344f0
commit
ba63dacbbb
|
@ -128,7 +128,7 @@ boost::optional<CTransaction> TransactionBuilder::Build()
|
|||
// Send change to the specified change address. If no change address
|
||||
// was set, send change to the first Sapling address given as input.
|
||||
if (zChangeAddr) {
|
||||
AddSaplingOutput(zChangeAddr->first, zChangeAddr->second, change, {});
|
||||
AddSaplingOutput(zChangeAddr->first, zChangeAddr->second, change);
|
||||
} else if (tChangeAddr) {
|
||||
// tChangeAddr has already been validated.
|
||||
assert(AddTransparentOutput(tChangeAddr.value(), change));
|
||||
|
@ -136,7 +136,7 @@ boost::optional<CTransaction> TransactionBuilder::Build()
|
|||
auto fvk = spends[0].expsk.full_viewing_key();
|
||||
auto note = spends[0].note;
|
||||
libzcash::SaplingPaymentAddress changeAddr(note.d, note.pk_d);
|
||||
AddSaplingOutput(fvk.ovk, changeAddr, change, {});
|
||||
AddSaplingOutput(fvk.ovk, changeAddr, change);
|
||||
} else {
|
||||
return boost::none;
|
||||
}
|
||||
|
|
|
@ -86,7 +86,7 @@ public:
|
|||
uint256 ovk,
|
||||
libzcash::SaplingPaymentAddress to,
|
||||
CAmount value,
|
||||
std::array<unsigned char, ZC_MEMO_SIZE> memo);
|
||||
std::array<unsigned char, ZC_MEMO_SIZE> memo = {{0xF6}});
|
||||
|
||||
// Assumes that the value correctly corresponds to the provided UTXO.
|
||||
void AddTransparentInput(COutPoint utxo, CScript scriptPubKey, CAmount value);
|
||||
|
|
Loading…
Reference in New Issue