From 5993b3c75aa7bcf86f035b748e372f660a4e42c1 Mon Sep 17 00:00:00 2001 From: Bill Somerville Date: Fri, 13 Nov 2020 18:29:23 +0000 Subject: [PATCH] backing out a smaller chunk of Boost::log functionality --- WSJTXLogging.cpp | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) diff --git a/WSJTXLogging.cpp b/WSJTXLogging.cpp index 76adf81b0..7da71144f 100644 --- a/WSJTXLogging.cpp +++ b/WSJTXLogging.cpp @@ -195,6 +195,8 @@ WSJTXLogging::~WSJTXLogging () // Reroute Qt messages to the system logger void WSJTXLogging::qt_log_handler (QtMsgType type, QMessageLogContext const& context, QString const& msg) { + std::cerr << "qt_log_handler: type: " << int(type) << " file: " << context.file << " line: " << context.line << " msg: " << msg.toStdString () << '\n'; + // Convert Qt message types to logger severities auto severity = trivial::trace; switch (type) @@ -221,17 +223,17 @@ void WSJTXLogging::qt_log_handler (QtMsgType type, QMessageLogContext const& con if (!context.category || !qstrcmp (context.category, "default")) { BOOST_LOG_SEV (log, severity) - << boost::log::add_value ("Line", context.line) - << boost::log::add_value ("File", file) - << boost::log::add_value ("Function", function) + // << boost::log::add_value ("Line", context.line) + // << boost::log::add_value ("File", file) + // << boost::log::add_value ("Function", function) << msg.toStdString (); } else { BOOST_LOG_CHANNEL_SEV (log, std::string {context.category}, severity) - << boost::log::add_value ("Line", context.line) - << boost::log::add_value ("File", file) - << boost::log::add_value ("Function", function) + // << boost::log::add_value ("Line", context.line) + // << boost::log::add_value ("File", file) + // << boost::log::add_value ("Function", function) << msg.toStdString (); } if (QtFatalMsg == type)