trivial|doc: Some trivial housekeeping (#4059)

* Fix extra line break in CommitTransaction log message

Introduced in #3680 ebe7e80a49 (diff-b2bb174788c7409b671c46ccc86034bdR4113)

* doc: Fix `quorum sign` help

* doc: Add `getdata` to quorum commands list help

* doc: Drop "P2WSH" from signrawtransactionwithkey help

* trivial: Replace "push_back(Pair(..))" with "pushKV"

* trivial: Reorder wallet cmd-line options

* git: Add macos debug simbols to .gitignore

* trivial: Fix typos and whitespaces, drop unused stuff
This commit is contained in:
UdjinM6 2021-03-26 15:11:11 +03:00 committed by GitHub
parent fc96e34f28
commit 83663c564e
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
12 changed files with 21 additions and 21 deletions

1
.gitignore vendored
View File

@ -100,6 +100,7 @@ qrc_*.cpp
# Mac specific
.DS_Store
build
*.dSYM
#lcov
*.gcno

View File

@ -96,7 +96,6 @@ static void BLS_Sign_Normal(benchmark::State& state)
{
CBLSSecretKey secKey;
secKey.MakeNewKey();
CBLSPublicKey pubKey = secKey.GetPublicKey();
// Benchmark.
while (state.KeepRunning()) {

View File

@ -841,7 +841,7 @@ void ThreadImport(std::vector<fs::path> vImportFiles)
{
// Get all UTXOs for each MN collateral in one go so that we can fill coin cache early
// and reduce further locking overhead for cs_main in other parts of code inclluding GUI
// and reduce further locking overhead for cs_main in other parts of code including GUI
LogPrintf("Filling coin cache with masternode UTXOs...\n");
LOCK(cs_main);
int64_t nStart = GetTimeMillis();
@ -1461,7 +1461,7 @@ bool AppInitParameterInteraction()
}
if (gArgs.IsArgSet("-dip3params")) {
// Allow overriding budget parameters for testing
// Allow overriding dip3 parameters for testing
if (!chainparams.MineBlocksOnDemand()) {
return InitError("DIP3 parameters may only be overridden on regtest.");
}

View File

@ -316,7 +316,7 @@ void CChainLocksHandler::TrySignChainTip()
}
if (HasChainLock(pindexWalk->nHeight, pindexWalk->GetBlockHash())) {
// we don't care about islocks for TXs that are ChainLocked already
LogPrint(BCLog::CHAINLOCKS, "CChainLocksHandler::%s -- chainlock at height %d \n", __func__, pindexWalk->nHeight);
LogPrint(BCLog::CHAINLOCKS, "CChainLocksHandler::%s -- chainlock at height %d\n", __func__, pindexWalk->nHeight);
break;
}

View File

@ -695,7 +695,7 @@ void CSigningManager::ProcessRecoveredSig(const std::shared_ptr<const CRecovered
auto signHash = CLLMQUtils::BuildSignHash(*recoveredSig);
LogPrint(BCLog::LLMQ, "CSigningManager::%s -- valid recSig. signHash=%s, id=%s, msgHash=%s\n", __func__,
signHash.ToString(), recoveredSig->id .ToString(), recoveredSig->msgHash.ToString());
signHash.ToString(), recoveredSig->id.ToString(), recoveredSig->msgHash.ToString());
if (db.HasRecoveredSigForId(llmqType, recoveredSig->id)) {
CRecoveredSig otherRecoveredSig;

View File

@ -150,8 +150,8 @@ UniValue getcoinjoininfo(const JSONRPCRequest& request)
coinJoinClientManagers.at(pwallet->GetName())->GetJsonInfo(obj);
obj.pushKV("keys_left", pwallet->nKeysLeftSinceAutoBackup);
obj.push_back(Pair("warnings", pwallet->nKeysLeftSinceAutoBackup < COINJOIN_KEYS_THRESHOLD_WARNING
? "WARNING: keypool is almost depleted!" : ""));
obj.pushKV("warnings", pwallet->nKeysLeftSinceAutoBackup < COINJOIN_KEYS_THRESHOLD_WARNING
? "WARNING: keypool is almost depleted!" : "");
#endif // ENABLE_WALLET
return obj;

View File

@ -908,7 +908,7 @@ UniValue signrawtransactionwithkey(const JSONRPCRequest& request)
" \"txid\":\"id\", (string, required) The transaction id\n"
" \"vout\":n, (numeric, required) The output number\n"
" \"scriptPubKey\": \"hex\", (string, required) script key\n"
" \"redeemScript\": \"hex\", (string, required for P2SH or P2WSH) redeem script\n"
" \"redeemScript\": \"hex\", (string, required for P2SH) redeem script\n"
" \"amount\": value (numeric, required) The amount spent\n"
" }\n"
" ,...\n"

View File

@ -287,7 +287,7 @@ UniValue quorum_memberof(const JSONRPCRequest& request)
void quorum_sign_help()
{
throw std::runtime_error(
"quorum sign llmqType \"id\" \"msgHash\" ( \"quorumHash\" )\n"
"quorum sign llmqType \"id\" \"msgHash\" ( \"quorumHash\" submit )\n"
"Threshold-sign a message\n"
"\nArguments:\n"
"1. llmqType (int, required) LLMQ type.\n"
@ -616,6 +616,7 @@ UniValue quorum_getdata(const JSONRPCRequest& request)
" getrecsig - Get a recovered signature\n"
" isconflicting - Test if a conflict exists\n"
" selectquorum - Return the quorum that would/should sign a request\n"
" getdata - Request quorum data from other masternodes in the quorum\n"
);
}

View File

@ -246,7 +246,6 @@ uint64_t nPruneTarget = 0;
int64_t nMaxTipAge = DEFAULT_MAX_TIP_AGE;
std::atomic<bool> fDIP0001ActiveAtTip{false};
std::atomic<bool> fDIP0003ActiveAtTip{false};
uint256 hashAssumeValid;
arith_uint256 nMinimumChainWork;

View File

@ -71,12 +71,12 @@ void WalletInit::AddWalletOptions() const
gArgs.AddArg("-spendzeroconfchange", strprintf("Spend unconfirmed change when sending transactions (default: %u)", DEFAULT_SPEND_ZEROCONF_CHANGE), false, OptionsCategory::WALLET);
gArgs.AddArg("-upgradewallet", "Upgrade wallet to latest format on startup", false, OptionsCategory::WALLET);
gArgs.AddArg("-wallet=<path>", "Specify wallet database path. Can be specified multiple times to load multiple wallets. Path is interpreted relative to <walletdir> if it is not absolute, and will be created if it does not exist (as a directory containing a wallet.dat file and log files). For backwards compatibility this will also accept names of existing data files in <walletdir>.)", false, OptionsCategory::WALLET);
gArgs.AddArg("-walletbackupsdir=<dir>", "Specify full path to directory for automatic wallet backups (must exist)", false, OptionsCategory::WALLET);
gArgs.AddArg("-walletbroadcast", strprintf("Make the wallet broadcast transactions (default: %u)", DEFAULT_WALLETBROADCAST), false, OptionsCategory::WALLET);
gArgs.AddArg("-walletdir=<dir>", "Specify directory to hold wallets (default: <datadir>/wallets if it exists, otherwise <datadir>)", false, OptionsCategory::WALLET);
gArgs.AddArg("-walletnotify=<cmd>", "Execute command when a wallet transaction changes (%s in cmd is replaced by TxID)", false, OptionsCategory::WALLET);
gArgs.AddArg("-zapwallettxes=<mode>", "Delete all wallet transactions and only recover those parts of the blockchain through -rescan on startup"
" (1 = keep tx meta data e.g. account owner and payment request information, 2 = drop tx meta data)", false, OptionsCategory::WALLET);
gArgs.AddArg("-walletbackupsdir=<dir>", "Specify full path to directory for automatic wallet backups (must exist)", false, OptionsCategory::WALLET);
gArgs.AddArg("-discardfee=<amt>", strprintf("The fee rate (in %s/kB) that indicates your tolerance for discarding change by adding it to the fee (default: %s). "
"Note: An output is discarded if it is dust at this rate, but we will always discard up to the dust relay fee and a discard fee above that is limited by the fee estimate for the longest target",
@ -96,9 +96,9 @@ void WalletInit::AddWalletOptions() const
gArgs.AddArg("-keepass", strprintf("Use KeePass 2 integration using KeePassHttp plugin (default: %u)", 0), false, OptionsCategory::WALLET_KEEPASS);
gArgs.AddArg("-keepassid=<id>", "KeePassHttp id for the established association", false, OptionsCategory::WALLET_KEEPASS);
gArgs.AddArg("-keepasskey=<key>", "KeePassHttp key for AES encrypted communication with KeePass", false, OptionsCategory::WALLET_KEEPASS);
gArgs.AddArg("-keepassname=<name>", "Name to construct url for KeePass entry that stores the wallet passphrase", false, OptionsCategory::WALLET_KEEPASS);
gArgs.AddArg("-keepassport=<port>", strprintf("Connect to KeePassHttp on port <port> (default: %u)", DEFAULT_KEEPASS_HTTP_PORT), false, OptionsCategory::WALLET_KEEPASS);
gArgs.AddArg("-keepasskey=<key>", "KeePassHttp key for AES encrypted communication with KeePass", false, OptionsCategory::WALLET_KEEPASS);
gArgs.AddArg("-enablecoinjoin", strprintf("Enable use of CoinJoin for funds stored in this wallet (0-1, default: %u)", 0), false, OptionsCategory::WALLET_COINJOIN);
gArgs.AddArg("-coinjoinamount=<n>", strprintf("Target CoinJoin balance (%u-%u, default: %u)", MIN_COINJOIN_AMOUNT, MAX_COINJOIN_AMOUNT, DEFAULT_COINJOIN_AMOUNT), false, OptionsCategory::WALLET_COINJOIN);

View File

@ -221,7 +221,7 @@ void CWallet::DeriveNewChildKey(WalletBatch &batch, const CKeyMetadata& metadata
}
if (!DecryptHDChain(hdChainTmp))
throw std::runtime_error(std::string(__func__) + ": DecryptHDChainSeed failed");
throw std::runtime_error(std::string(__func__) + ": DecryptHDChain failed");
// make sure seed matches this chain
if (hdChainTmp.GetID() != hdChainTmp.GetSeedHash())
throw std::runtime_error(std::string(__func__) + ": Wrong HD chain!");
@ -300,7 +300,7 @@ bool CWallet::GetKey(const CKeyID &address, CKey& keyOut) const
if (!GetHDChain(hdChainCurrent))
throw std::runtime_error(std::string(__func__) + ": GetHDChain failed");
if (!DecryptHDChain(hdChainCurrent))
throw std::runtime_error(std::string(__func__) + ": DecryptHDChainSeed failed");
throw std::runtime_error(std::string(__func__) + ": DecryptHDChain failed");
// make sure seed matches this chain
if (hdChainCurrent.GetID() != hdChainCurrent.GetSeedHash())
throw std::runtime_error(std::string(__func__) + ": Wrong HD chain!");
@ -4033,7 +4033,7 @@ bool CWallet::CommitTransaction(CTransactionRef tx, mapValue_t mapValue, std::ve
wtxNew.fTimeReceivedIsTxTime = true;
wtxNew.fFromMe = true;
LogPrintf("CommitTransaction:\n%s\n", wtxNew.tx->ToString());
LogPrintf("CommitTransaction:\n%s", wtxNew.tx->ToString()); /* Continued */
{
// Take key pair from key pool so it won't be used again
reservekey.KeepKey();