mirror of
https://github.com/bitcoin/bitcoin.git
synced 2025-11-12 15:09:59 +01:00
refactor: Make const refs vars where applicable
This avoids initializing variables with the copy-constructor of a non-trivially copyable type.
This commit is contained in:
@@ -296,7 +296,7 @@ bool CCoinsViewErrorCatcher::GetCoin(const COutPoint &outpoint, Coin &coin) cons
|
||||
try {
|
||||
return CCoinsViewBacked::GetCoin(outpoint, coin);
|
||||
} catch(const std::runtime_error& e) {
|
||||
for (auto f : m_err_callbacks) {
|
||||
for (const auto& f : m_err_callbacks) {
|
||||
f();
|
||||
}
|
||||
LogPrintf("Error reading from database: %s\n", e.what());
|
||||
|
||||
Reference in New Issue
Block a user