tshark: recognize protocol aliases such as "-O ssl"

Be sure to map "ssl" to "tls" instead of silently ignoring it.

Change-Id: If1edc10ead4a9f25ee4802e1395390dc3c51796f
Reviewed-on: https://code.wireshark.org/review/31894
Petri-Dish: Peter Wu <peter@lekensteyn.nl>
Tested-by: Petri Dish Buildbot
Reviewed-by: Peter Wu <peter@lekensteyn.nl>
This commit is contained in:
Peter Wu 2019-02-05 14:01:03 +01:00
parent f2df0fc88d
commit 62a8d40b5f
1 changed files with 6 additions and 1 deletions

View File

@ -1586,7 +1586,12 @@ main(int argc, char *argv[])
output_only_tables = g_hash_table_new (g_str_hash, g_str_equal);
for (ps = strtok (output_only, ","); ps; ps = strtok (NULL, ",")) {
g_hash_table_insert(output_only_tables, (gpointer)ps, (gpointer)ps);
const char *name = ps;
header_field_info *hfi = proto_registrar_get_byalias(name);
if (hfi) {
name = hfi->abbrev;
}
g_hash_table_insert(output_only_tables, (gpointer)name, (gpointer)name);
}
}