diff --git a/src/rpc/rawtransaction.cpp b/src/rpc/rawtransaction.cpp index 0fcb5411b..71b28c642 100644 --- a/src/rpc/rawtransaction.cpp +++ b/src/rpc/rawtransaction.cpp @@ -1,6 +1,6 @@ // Copyright (c) 2010 Satoshi Nakamoto // Copyright (c) 2009-2015 The Bitcoin Core developers -// Copyright (c) 2019 The Hush developers +// Copyright (c) 2019-2020 The Hush developers // Distributed under the MIT software license, see the accompanying // file COPYING or http://www.opensource.org/licenses/mit-license.php. @@ -1377,6 +1377,7 @@ UniValue sendrawtransaction(const UniValue& params, bool fHelp, const CPubKey& m // push to local node and sync with wallets CValidationState state; bool fMissingInputs; + LogPrintf("%s: Submitting to mempool\n", __FUNCTION__); if (!AcceptToMemoryPool(mempool, state, tx, false, &fMissingInputs, !fOverrideFees)) { if (state.IsInvalid()) { throw JSONRPCError(RPC_TRANSACTION_REJECTED, strprintf("%i: %s", state.GetRejectCode(), state.GetRejectReason())); @@ -1390,6 +1391,7 @@ UniValue sendrawtransaction(const UniValue& params, bool fHelp, const CPubKey& m } else if (fHaveChain) { throw JSONRPCError(RPC_TRANSACTION_ALREADY_IN_CHAIN, "transaction already in block chain"); } + LogPrintf("%s: Relaying raw tx to mempool\n", __FUNCTION__); RelayTransaction(tx); } else diff --git a/src/transaction_builder.cpp b/src/transaction_builder.cpp index 07e201326..773792ba3 100644 --- a/src/transaction_builder.cpp +++ b/src/transaction_builder.cpp @@ -1,4 +1,7 @@ // Copyright (c) 2018 The Zcash developers +// Copyright (c) 2019-2020 The Hush developers +// Released under the GPLv3 + // Distributed under the MIT software license, see the accompanying // file COPYING or http://www.opensource.org/licenses/mit-license.php. @@ -9,6 +12,7 @@ #include "script/sign.h" #include +#include #include SpendDescriptionInfo::SpendDescriptionInfo( @@ -169,6 +173,7 @@ boost::optional TransactionBuilder::Build() auto ctx = librustzcash_sapling_proving_ctx_init(); + LogPrintf("%s: Creating Sapling SpendDescriptions\n", __FUNCTION__); // Create Sapling SpendDescriptions for (auto spend : spends) { auto cm = spend.note.cm(); @@ -203,6 +208,7 @@ boost::optional TransactionBuilder::Build() sdesc.anchor = spend.anchor; sdesc.nullifier = *nf; + LogPrintf("%s: Created cm + nullifier=%s\n", __FUNCTION__, sdesc.nullifier.ToString().c_str() ); mtx.vShieldedSpend.push_back(sdesc); } diff --git a/src/wallet/asyncrpcoperation_sendmany.cpp b/src/wallet/asyncrpcoperation_sendmany.cpp index 6434205b3..0230b57d0 100644 --- a/src/wallet/asyncrpcoperation_sendmany.cpp +++ b/src/wallet/asyncrpcoperation_sendmany.cpp @@ -50,6 +50,7 @@ #include #include "paymentdisclosuredb.h" +#include using namespace libzcash; @@ -504,6 +505,7 @@ bool AsyncRPCOperation_sendmany::main_impl() { auto addr = DecodePaymentAddress(address); assert(boost::get(&addr) != nullptr); auto to = boost::get(addr); + LogPrintf("%s: Adding Sapling output to address %s\n", __FUNCTION__, to.GetHash().ToString().c_str()); auto memo = get_memo_from_hex_string(hexMemo);