1
0
Fork 0
forked from lthn/blockchain

undo global changes

This commit is contained in:
cryptozoidberg 2022-05-09 20:32:36 +02:00
parent c53da67e1a
commit 60c5cc24bc
No known key found for this signature in database
GPG key ID: 22DEB97A54C6FDEC
2 changed files with 4 additions and 2 deletions

View file

@ -602,12 +602,13 @@ namespace currency
//extra
std::vector<extra_v> extra;
std::vector<txin_v> vin;
std::vector<tx_out_v> vout_;//std::vector<tx_out> vout;
std::vector<tx_out> vout;//std::vector<tx_out> vout;
BEGIN_SERIALIZE()
VARINT_FIELD(version)
if(CURRENT_TRANSACTION_VERSION < version) return false;
FIELD(vin)
if(version <= 1)
FIELD(vout)
FIELD(extra)
END_SERIALIZE()

View file

@ -1209,6 +1209,7 @@ namespace currency
{
//extra copy operation, but creating transaction is not sensitive to this
finalize_tx_param ftp = AUTO_VAL_INIT(ftp);
ftp.tx_version = CURRENT_TRANSACTION_VERSION;
ftp.sources = sources;
ftp.prepared_destinations = destinations;
ftp.extra = extra;
@ -1264,7 +1265,7 @@ namespace currency
tx.signatures.clear();
tx.extra = extra;
tx.version = CURRENT_TRANSACTION_VERSION;
tx.version = ftp.tx_version;
if (unlock_time != 0)
set_tx_unlock_time(tx, unlock_time);