diff --git a/src/qt/sendcoinsdialog.cpp b/src/qt/sendcoinsdialog.cpp --- a/src/qt/sendcoinsdialog.cpp +++ b/src/qt/sendcoinsdialog.cpp @@ -216,7 +216,7 @@ coinControlUpdateLabels(); // fee section - for (const int &n : confTargets) { + for (const int n : confTargets) { ui->confTargetSelector->addItem( tr("%1 (%2 blocks)") .arg(GUIUtil::formatNiceTimeOffset( diff --git a/src/streams.h b/src/streams.h --- a/src/streams.h +++ b/src/streams.h @@ -222,10 +222,10 @@ vch.clear(); nReadPos = 0; } - iterator insert(iterator it, const char &x = char()) { + iterator insert(iterator it, const char x = char()) { return vch.insert(it, x); } - void insert(iterator it, size_type n, const char &x) { + void insert(iterator it, size_type n, const char x) { vch.insert(it, n, x); } value_type *data() { return vch.data() + nReadPos; } diff --git a/src/wallet/rpcdump.cpp b/src/wallet/rpcdump.cpp --- a/src/wallet/rpcdump.cpp +++ b/src/wallet/rpcdump.cpp @@ -885,9 +885,9 @@ data.exists("pubkeys") ? data["pubkeys"].get_array() : UniValue(); const UniValue &keys = data.exists("keys") ? data["keys"].get_array() : UniValue(); - const bool &internal = + const bool internal = data.exists("internal") ? data["internal"].get_bool() : false; - const bool &watchOnly = + const bool watchOnly = data.exists("watchonly") ? data["watchonly"].get_bool() : false; const std::string &label = data.exists("label") && !internal ? data["label"].get_str() : ""; diff --git a/src/wallet/wallet.h b/src/wallet/wallet.h --- a/src/wallet/wallet.h +++ b/src/wallet/wallet.h @@ -430,8 +430,8 @@ Amount GetCredit(const isminefilter &filter) const; Amount GetImmatureCredit(bool fUseCache = true) const; Amount GetAvailableCredit(bool fUseCache = true) const; - Amount GetImmatureWatchOnlyCredit(const bool &fUseCache = true) const; - Amount GetAvailableWatchOnlyCredit(const bool &fUseCache = true) const; + Amount GetImmatureWatchOnlyCredit(const bool fUseCache = true) const; + Amount GetAvailableWatchOnlyCredit(const bool fUseCache = true) const; Amount GetChange() const; void GetAmounts(std::list &listReceived, @@ -830,9 +830,9 @@ const Amount nMinimumAmount = SATOSHI, const Amount nMaximumAmount = MAX_MONEY, const Amount nMinimumSumAmount = MAX_MONEY, - const uint64_t &nMaximumCount = 0, - const int &nMinDepth = 0, - const int &nMaxDepth = 9999999) const; + const uint64_t nMaximumCount = 0, + const int nMinDepth = 0, + const int nMaxDepth = 9999999) const; /** * Return list of available coins and locked coins grouped by non-change diff --git a/src/wallet/wallet.cpp b/src/wallet/wallet.cpp --- a/src/wallet/wallet.cpp +++ b/src/wallet/wallet.cpp @@ -1963,7 +1963,7 @@ return nCredit; } -Amount CWalletTx::GetImmatureWatchOnlyCredit(const bool &fUseCache) const { +Amount CWalletTx::GetImmatureWatchOnlyCredit(const bool fUseCache) const { if (IsImmatureCoinBase() && IsInMainChain()) { if (fUseCache && fImmatureWatchCreditCached) { return nImmatureWatchCreditCached; @@ -1978,7 +1978,7 @@ return Amount::zero(); } -Amount CWalletTx::GetAvailableWatchOnlyCredit(const bool &fUseCache) const { +Amount CWalletTx::GetAvailableWatchOnlyCredit(const bool fUseCache) const { if (pwallet == nullptr) { return Amount::zero(); } @@ -2294,8 +2294,8 @@ const Amount nMinimumAmount, const Amount nMaximumAmount, const Amount nMinimumSumAmount, - const uint64_t &nMaximumCount, - const int &nMinDepth, const int &nMaxDepth) const { + const uint64_t nMaximumCount, const int nMinDepth, + const int nMaxDepth) const { vCoins.clear(); Amount nTotal = Amount::zero();