@@ -614,7 +614,7 @@ UniValue combinerawtransaction(const JSONRPCRequest& request)
614614 std::vector<CMutableTransaction> txVariants (txs.size ());
615615
616616 for (unsigned int idx = 0 ; idx < txs.size (); idx++) {
617- if (!DecodeHexTx (txVariants[idx], txs[idx].get_str (), true )) {
617+ if (!DecodeHexTx (txVariants[idx], txs[idx].get_str ())) {
618618 throw JSONRPCError (RPC_DESERIALIZATION_ERROR, strprintf (" TX decode failed for tx %d" , idx));
619619 }
620620 }
@@ -655,18 +655,13 @@ UniValue combinerawtransaction(const JSONRPCRequest& request)
655655 throw JSONRPCError (RPC_VERIFY_ERROR, " Input not found or already spent" );
656656 }
657657 const CScript& prevPubKey = coin.out .scriptPubKey ;
658- const CAmount& amount = coin.out .nValue ;
659-
660- SignatureData sigdata;
661658
662659 // ... and merge in other signatures:
663660 for (const CMutableTransaction& txv : txVariants) {
664661 if (txv.vin .size () > i) {
665- sigdata = CombineSignatures (prevPubKey, TransactionSignatureChecker (&txConst, i, amount ), sigdata, DataFromTransaction ( txv, i) );
662+ txin. scriptSig = CombineSignatures (prevPubKey, TransactionSignatureChecker (&txConst, i), txin. scriptSig , txv. vin [i]. scriptSig );
666663 }
667664 }
668-
669- UpdateTransaction (mergedTx, i, sigdata);
670665 }
671666
672667 return EncodeHexTx (mergedTx);
@@ -744,7 +739,7 @@ UniValue signrawtransaction(const JSONRPCRequest& request)
744739 RPCTypeCheck (request.params , {UniValue::VSTR, UniValue::VARR, UniValue::VARR, UniValue::VSTR}, true );
745740
746741 CMutableTransaction mtx;
747- if (!DecodeHexTx (mtx, request.params [0 ].get_str (), true ))
742+ if (!DecodeHexTx (mtx, request.params [0 ].get_str ()))
748743 throw JSONRPCError (RPC_DESERIALIZATION_ERROR, " TX decode failed" );
749744
750745 // Fetch previous transactions (inputs):
0 commit comments