Consensus: Add asset type to CTxOut and validation

This commit is contained in:
Gregory Sanders 2016-12-01 09:34:31 -05:00
parent c63b8e9803
commit 05bc6db085
19 changed files with 196 additions and 90 deletions

View file

@ -486,7 +486,7 @@ UniValue createrawtransaction(const UniValue& params, bool fHelp)
if (name_ == "data") {
std::vector<unsigned char> data = ParseHexV(sendTo[name_].getValStr(),"Data");
CTxOut out(0, CScript() << OP_RETURN << data);
CTxOut out(BITCOINID, 0, CScript() << OP_RETURN << data);
rawTx.vout.push_back(out);
} else {
CBitcoinAddress address(name_);
@ -502,7 +502,7 @@ UniValue createrawtransaction(const UniValue& params, bool fHelp)
outputValue += nAmount;
CTxOut out(nAmount, scriptPubKey);
CTxOut out(BITCOINID, nAmount, scriptPubKey);
if (address.IsBlinded()) {
CPubKey confidentiality_pubkey = address.GetBlindingKey();
if (!confidentiality_pubkey.IsValid())