diff options
author | Martin Kaiser <wireshark@kaiser.cx> | 2015-04-04 19:15:50 +0200 |
---|---|---|
committer | Martin Kaiser <wireshark@kaiser.cx> | 2015-04-04 17:18:28 +0000 |
commit | 2b7f87587c2aa64a1f8c10c5beb66542e7ec5260 (patch) | |
tree | 44ed753562367073a789310b77d7d11320d0c0d8 /epan/print.c | |
parent | e4da62fefe4f52cccca28875c0e893e69a184152 (diff) | |
download | wireshark-2b7f87587c2aa64a1f8c10c5beb66542e7ec5260.tar.gz |
change several (mutually exclusive) if statements into one big if-else
Change-Id: Ib3614431c3ff8f6e53fa0993e296ffea70926d03
Reviewed-on: https://code.wireshark.org/review/7911
Reviewed-by: Martin Kaiser <wireshark@kaiser.cx>
Diffstat (limited to 'epan/print.c')
-rw-r--r-- | epan/print.c | 12 |
1 files changed, 4 insertions, 8 deletions
diff --git a/epan/print.c b/epan/print.c index ad4ef5cc0d..1c2692dc84 100644 --- a/epan/print.c +++ b/epan/print.c @@ -1134,8 +1134,7 @@ gboolean output_fields_set_option(output_fields_t *info, gchar *option) } return TRUE; } - - if (0 == strcmp(option_name, "separator")) { + else if (0 == strcmp(option_name, "separator")) { switch (*option_value) { case '/': switch (*++option_value) { @@ -1155,8 +1154,7 @@ gboolean output_fields_set_option(output_fields_t *info, gchar *option) } return TRUE; } - - if (0 == strcmp(option_name, "occurrence")) { + else if (0 == strcmp(option_name, "occurrence")) { switch (*option_value) { case 'f': case 'l': @@ -1168,8 +1166,7 @@ gboolean output_fields_set_option(output_fields_t *info, gchar *option) } return TRUE; } - - if (0 == strcmp(option_name, "aggregator")) { + else if (0 == strcmp(option_name, "aggregator")) { switch (*option_value) { case '/': switch (*++option_value) { @@ -1186,8 +1183,7 @@ gboolean output_fields_set_option(output_fields_t *info, gchar *option) } return TRUE; } - - if (0 == strcmp(option_name, "quote")) { + else if (0 == strcmp(option_name, "quote")) { switch (*option_value) { case 'd': info->quote = '"'; |