aboutsummaryrefslogtreecommitdiff
path: root/src/logging.cpp
diff options
context:
space:
mode:
authorAnthony Towns <aj@erisian.com.au>2023-08-23 10:02:03 +1000
committerAnthony Towns <aj@erisian.com.au>2023-12-15 11:03:25 +1000
commitab34dc6012351e7b8aab871dd9d2b38ade1cd9bc (patch)
treea4991b559154c405c844a95c8f43f66510a94961 /src/logging.cpp
parentdfe98b6874da04e45f68d17575c1e8a5431ca9bc (diff)
downloadbitcoin-ab34dc6012351e7b8aab871dd9d2b38ade1cd9bc.tar.xz
logging: Log Info messages unconditionally
Previously Info-level logging when a category was specified (via LogPrintLevel) would only print the corresponding log message if `-debug=category` were specified, while Info-level logging without a category would always be printed. Make this more consistent by having Info messages always be logged, whether they include a category or not.
Diffstat (limited to 'src/logging.cpp')
-rw-r--r--src/logging.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/logging.cpp b/src/logging.cpp
index b23a6f96eb..d516cd65a5 100644
--- a/src/logging.cpp
+++ b/src/logging.cpp
@@ -126,9 +126,9 @@ bool BCLog::Logger::WillLogCategory(BCLog::LogFlags category) const
bool BCLog::Logger::WillLogCategoryLevel(BCLog::LogFlags category, BCLog::Level level) const
{
- // Log messages at Warning and Error level unconditionally, so that
+ // Log messages at Info, Warning and Error level unconditionally, so that
// important troubleshooting information doesn't get lost.
- if (level >= BCLog::Level::Warning) return true;
+ if (level >= BCLog::Level::Info) return true;
if (!WillLogCategory(category)) return false;