From 9f4671f674ca70a3d7d33f22daf0bd88a7e8ff8d Mon Sep 17 00:00:00 2001 From: Guy Harris Date: Sun, 11 Jun 2017 12:03:59 -0700 Subject: [PATCH] Don't colorize a line if we have no color filter. There's no guarantee that there's a color filter that matches, so the color filter pointer might be null. Change-Id: Ia11845824a4ca9c0cc153a89aa2fba876084a796 Reviewed-on: https://code.wireshark.org/review/22079 Reviewed-by: Guy Harris --- tshark.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tshark.c b/tshark.c index f15e49a002..1c4c618a3f 100644 --- a/tshark.c +++ b/tshark.c @@ -3840,7 +3840,7 @@ print_columns(capture_file *cf, const epan_dissect_t *edt) } } - if (dissect_color) + if (dissect_color && color_filter != NULL) return print_line_color(print_stream, 0, line_bufp, &color_filter->fg_color, &color_filter->bg_color); else return print_line(print_stream, 0, line_bufp);