From 8d9d3ff795c34fb4088244b9cffad333b651d247 Mon Sep 17 00:00:00 2001 From: Tomasz Wlostowski Date: Tue, 21 Jul 2020 11:42:34 +0200 Subject: [PATCH] qa/drc_proto: debug level settable by env var --- qa/drc_proto/drc_engine.cpp | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/qa/drc_proto/drc_engine.cpp b/qa/drc_proto/drc_engine.cpp index c073671c11..301be51266 100644 --- a/qa/drc_proto/drc_engine.cpp +++ b/qa/drc_proto/drc_engine.cpp @@ -116,7 +116,15 @@ static const int drc_debug_level = 2; void test::drc_dbg( int level, const char* fmt, ... ) { #ifdef DEBUG - if(level < drc_debug_level) // fixme: tom's debugging. + long dlevel = drc_debug_level; + wxString dlevelstr; + if( wxGetEnv( "DRC_DEBUG_LEVEL", &dlevelstr ) ) + { + dlevelstr.ToLong( &dlevel ); + } + + + if(level < dlevel) // fixme: tom's debugging. { va_list ap; va_start( ap, fmt );