From 697a7e93087ef778ff5da24cdb93231d6d1be6b8 Mon Sep 17 00:00:00 2001 From: Sultan Alsawaf Date: Mon, 4 Oct 2021 13:53:59 -0700 Subject: [PATCH] staprun: make the previous commit obey the color_errors switch again The color_errors check inside print_color() was not preserved. Fix it. --- staprun/staprun.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/staprun/staprun.h b/staprun/staprun.h index 5c814b902..d47c345e8 100644 --- a/staprun/staprun.h +++ b/staprun/staprun.h @@ -85,7 +85,7 @@ do { \ int num; \ \ /* Build the final format string so there's only one eprintf() call */ \ - seq = color ? parse_stap_color(color) : NULL; \ + seq = color && color_errors ? parse_stap_color(color) : NULL; \ if (seq) \ num = snprintf(NULL, 0, COLOR_FMT "%s " COLOR_RESET "%s", seq, \ tag, fmt); \ -- 2.43.5