aboutsummaryrefslogtreecommitdiffstats
path: root/epan/column.c
diff options
context:
space:
mode:
authorPeter Wu <peter@lekensteyn.nl>2019-02-08 18:52:09 +0100
committerPeter Wu <peter@lekensteyn.nl>2019-02-10 16:12:59 +0000
commit720c3bdc04621cc9aacee3d1ff15454ba81b9695 (patch)
treeecfcf382394beb0af5b92b41152d39685402a0e7 /epan/column.c
parent567fe966b1ca9a4c00f9989de9a38cfe8ebfbd14 (diff)
column: set G_REGEX_RAW for the custom column filter
Neither the pattern nor the intended subject (a custom fields filter) contain UTF-8, so set G_REGEX_RAW accordingly. While a filter such as `tcp matches "foo\xff"` (with `\xff` being a single byte) was accepted, it did not trigger a crash though even if the precondition was violated. Change-Id: I45d76b9abbd942d186dcf70f581121769bbd2d0a Ping-Bug: 14905 Reviewed-on: https://code.wireshark.org/review/31940 Petri-Dish: Peter Wu <peter@lekensteyn.nl> Tested-by: Petri Dish Buildbot Reviewed-by: Peter Wu <peter@lekensteyn.nl>
Diffstat (limited to 'epan/column.c')
-rw-r--r--epan/column.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/epan/column.c b/epan/column.c
index 96e1e96d73..ad49ec0d36 100644
--- a/epan/column.c
+++ b/epan/column.c
@@ -785,7 +785,8 @@ get_column_tooltip(const gint col)
}
fields = g_regex_split_simple(COL_CUSTOM_PRIME_REGEX, cfmt->custom_fields,
- G_REGEX_ANCHORED, G_REGEX_MATCH_ANCHORED);
+ (GRegexCompileFlags) (G_REGEX_ANCHORED | G_REGEX_RAW),
+ G_REGEX_MATCH_ANCHORED);
column_tooltip = g_string_new("");
for (i = 0; i < g_strv_length(fields); i++) {