diff --git a/src/libslic3r/utils.cpp b/src/libslic3r/utils.cpp index 08f9d430d8..29c9bad1c0 100644 --- a/src/libslic3r/utils.cpp +++ b/src/libslic3r/utils.cpp @@ -123,6 +123,14 @@ unsigned get_logging_level() } } +// Force set_logging_level(<=error) after loading of the DLL. +// This is used ot disable logging for unit and integration tests. +static struct RunOnInit { + RunOnInit() { + set_logging_level(1); + } +} g_RunOnInit; + void enforce_thread_count(const std::size_t count) { // Disable parallelization to simplify debugging.