MCPcopy Create free account
hub / github.com/0xShug0/audio.cpp / configure_logging

Function configure_logging

src/framework/debug/trace.cpp:96–108  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

94 }
95 return "unknown";
96}
97
98void configure_logging(const LoggingConfig & config) {
99 std::lock_guard<std::mutex> lock(logger_mutex());
100 auto & state = logger_state();
101 logger_enabled_flag().store(false, std::memory_order_release);
102 if (state.file_path != config.file_path) {
103 state.file_stream.reset();
104 }
105 state.file_path = config.file_path;
106 if (config.enabled && state.file_path.has_value() && !state.file_path->empty()) {
107 (void)logger_output_locked(state);
108 }
109 logger_enabled_flag().store(config.enabled, std::memory_order_release);
110}
111

Callers 12

reset_loggingFunction · 0.85
mainFunction · 0.85
mainFunction · 0.85
mainFunction · 0.85
mainFunction · 0.85
mainFunction · 0.85
mainFunction · 0.85
mainFunction · 0.85
mainFunction · 0.85
mainFunction · 0.85
mainFunction · 0.85
mainFunction · 0.85

Calls 2

resetMethod · 0.45
emptyMethod · 0.45

Tested by

no test coverage detected