diff --git a/ChangeLog b/ChangeLog index 00e1732..0b0cf73 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,8 @@ 2018-04-17 master - Update AUTHORS +- Fixes: + - Fix leak in image loading (issue #704) + - Executors no longer log unless env var DEBUG_EXECUTORS is set 2018-04-17 16.3 - Fixes: diff --git a/src/execplugin/execplugin.c b/src/execplugin/execplugin.c index 78d8ec5..cb4e936 100644 --- a/src/execplugin/execplugin.c +++ b/src/execplugin/execplugin.c @@ -20,6 +20,8 @@ #define MAX_TOOLTIP_LEN 4096 +bool debug_executors = false; + void execp_timer_callback(void *arg); char *execp_get_tooltip(void *obj); void execp_init_fonts(); @@ -635,7 +637,8 @@ void execp_timer_callback(void *arg) close(pipe_fd_stderr[0]); return; } else if (child == 0) { - fprintf(stderr, "tint2: Executing: %s\n", execp->backend->command); + if (debug_executors) + fprintf(stderr, "tint2: Executing: %s\n", execp->backend->command); // We are in the child close(pipe_fd_stdout[0]); dup2(pipe_fd_stdout[1], 1); // 1 is stdout diff --git a/src/execplugin/execplugin.h b/src/execplugin/execplugin.h index d410935..bb186bd 100644 --- a/src/execplugin/execplugin.h +++ b/src/execplugin/execplugin.h @@ -8,6 +8,8 @@ #include "common.h" #include "timer.h" +extern bool debug_executors; + // Architecture: // Panel panel_config contains an array of Execp, each storing all config options and all the state variables. // Only these run commands. diff --git a/src/init.c b/src/init.c index 6d3ac09..9104a08 100644 --- a/src/init.c +++ b/src/init.c @@ -106,6 +106,7 @@ void handle_env_vars() debug_dnd = getenv("DEBUG_DND") != NULL; debug_thumbnails = getenv("DEBUG_THUMBNAILS") != NULL; debug_timers = getenv("DEBUG_TIMERS") != NULL; + debug_executors = getenv("DEBUG_EXECUTORS") != NULL; if (debug_fps) { init_fps_distribution(); char *s = getenv("TRACING_FPS_THRESHOLD");