ioc: add pvxs_log_config() and pvxs_log_reset()

This commit is contained in:
Michael Davidsaver committed 2025-11-19 17:54:10 -08:00
1 parent 676afa5da2
commit 35c7cc5d15
5 files changed
+49 -8

No files matched your search

+10 -5
View File
@@ -340,12 +340,8 @@ void logger_level_clear()
logger_gbl->config.clear();
}
void logger_config_env()
void logger_config_str(const char *env)
{
const char *env = getenv("PVXS_LOG");
if(!env || !*env)
return;
threadOnce<&logger_prepare>();
Guard G(logger_gbl->lock);
@@ -389,6 +385,15 @@ void logger_config_env()
errlogFlush();
}
void logger_config_env()
{
const char *env = getenv("PVXS_LOG");
if(!env || !*env)
return;
logger_config_str(env);
}
} // namespace pvxs
namespace pvxs {namespace impl {