mirror of
https://github.com/ElementsProject/elements.git
synced 2026-08-14 12:43:40 +02:00
rawissueasset: don't make explicit 0-value which gets blinded later
This commit is contained in:
parent
1b78b9f222
commit
d710cb5880
1 changed files with 1 additions and 4 deletions
|
|
@ -2386,11 +2386,8 @@ void issueasset_base(CMutableTransaction& mtx, RawIssuanceDetails& issuance_deta
|
|||
token_out.nNonce.vchCommitment = std::vector<unsigned char>(token_blind.begin(), token_blind.end());
|
||||
}
|
||||
// Explicit 0 is represented by a null value, don't set to non-null in that case
|
||||
if (blind_issuance || token_amount != 0) {
|
||||
mtx.vin[issuance_input_index].assetIssuance.nInflationKeys = token_amount;
|
||||
}
|
||||
// Don't make zero value output(impossible by consensus)
|
||||
if (token_amount > 0) {
|
||||
mtx.vin[issuance_input_index].assetIssuance.nInflationKeys = token_amount;
|
||||
mtx.vout.insert(mtx.vout.begin()+token_place, token_out);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue