Mar 13th 2023 update

This commit is contained in:
Ned Wright
2023-03-13 19:02:52 +00:00
parent 03f4d6bf39
commit a9f917d638
40 changed files with 587 additions and 532 deletions

View File

@@ -280,6 +280,8 @@ Debug::Debug(
:
do_assert(false)
{
isCommunicationFlag(flag1);
auto current_configuration =
Singleton::exists<Config::I_Config>() ? getConfigurationWithDefault(default_config, "Debug") : default_config;
for (auto &stream : current_configuration.streams_in_context) {
@@ -309,6 +311,9 @@ Debug::Debug(
:
do_assert(false)
{
isCommunicationFlag(flag1);
isCommunicationFlag(flag2);
auto current_configuration =
Singleton::exists<Config::I_Config>() ? getConfigurationWithDefault(default_config, "Debug") : default_config;
@@ -344,6 +349,10 @@ Debug::Debug(
:
do_assert(false)
{
isCommunicationFlag(flag1);
isCommunicationFlag(flag2);
isCommunicationFlag(flag3);
auto current_configuration =
Singleton::exists<Config::I_Config>() ? getConfigurationWithDefault(default_config, "Debug") : default_config;
@@ -382,6 +391,11 @@ Debug::Debug(
:
do_assert(false)
{
isCommunicationFlag(flag1);
isCommunicationFlag(flag2);
isCommunicationFlag(flag3);
isCommunicationFlag(flag4);
auto current_configuration =
Singleton::exists<Config::I_Config>() ? getConfigurationWithDefault(default_config, "Debug") : default_config;
@@ -694,6 +708,7 @@ Debug::findDebugFilePrefix(const string &file_name)
void
Debug::addActiveStream(const string &name)
{
if (is_communication && name == "FOG") return;
auto stream_entry = active_streams.find(name);
if (stream_entry != active_streams.end()) {
current_active_streams.insert(stream_entry->second);
@@ -735,6 +750,12 @@ Debug::startStreams(
is_debug_running = true;
}
void
Debug::isCommunicationFlag(const DebugFlags &flag)
{
is_communication |= (flag == D_HTTP_REQUEST || flag == D_COMMUNICATION);
}
Debug::DebugLevel Debug::lowest_global_level = default_level;
I_TimeGet *Debug::time = nullptr;
I_MainLoop *Debug::mainloop = nullptr;

View File

@@ -24,6 +24,7 @@ USE_DEBUG_FLAG(D_FW);
USE_DEBUG_FLAG(D_PM);
USE_DEBUG_FLAG(D_PM_EXEC);
USE_DEBUG_FLAG(D_TRACE);
USE_DEBUG_FLAG(D_HTTP_REQUEST);
string line = "";