aboutsummaryrefslogtreecommitdiffstats
path: root/epan/ftypes
diff options
context:
space:
mode:
authorPascal Quantin <pascal.quantin@gmail.com>2018-11-01 07:48:25 +0000
committerPascal Quantin <pascal.quantin@gmail.com>2018-11-01 07:49:02 +0000
commit4a5812aca2a388580f32140a7212d0da4eca0162 (patch)
tree241d9247f157b2fd68849a12f65dda28feee7b97 /epan/ftypes
parentbcaf997f8af1ac0c718140977d1b4f98a3321533 (diff)
Revert "FT_BYTES: fix dissection of FT_BYTES when using SEP_SPACE and "NONE" options"
This reverts commit 0457e6041942776ecff9d4377fc0ce5a340dbb7a. Change-Id: Id39722872efbe98648754d7543da7ae5b08f8b67 Reviewed-on: https://code.wireshark.org/review/30451 Reviewed-by: Pascal Quantin <pascal.quantin@gmail.com>
Diffstat (limited to 'epan/ftypes')
-rw-r--r--epan/ftypes/ftype-bytes.c38
1 files changed, 9 insertions, 29 deletions
diff --git a/epan/ftypes/ftype-bytes.c b/epan/ftypes/ftype-bytes.c
index e591c5bbf4..c1d57f0bbd 100644
--- a/epan/ftypes/ftype-bytes.c
+++ b/epan/ftypes/ftype-bytes.c
@@ -139,44 +139,24 @@ bytes_to_repr(fvalue_t *fv, ftrepr_t rtype, int field_display, char *buf, unsign
separator = '-';
break;
case SEP_SPACE:
- separator = ' ';
- break;
case SEP_COLON:
- separator = ':';
- break;
- case SEP_NONE:
- break;
case BASE_NONE:
default:
separator = ':';
break;
}
- if(FIELD_DISPLAY(field_display) != SEP_NONE){
- if (fv->value.bytes->len) {
- buf = bytes_to_hexstr_punct(buf, fv->value.bytes->data, fv->value.bytes->len, separator);
- }
- else {
- if (rtype == FTREPR_DFILTER) {
- /* An empty byte array in a display filter is represented as "" */
- *buf++ = '"';
- *buf++ = '"';
- }
- }
- *buf = '\0';
- }else{
- if (fv->value.bytes->len) {
- buf = bytes_to_hexstr(buf, fv->value.bytes->data, fv->value.bytes->len);
- }
- else {
- if (rtype == FTREPR_DFILTER) {
- /* An empty byte array in a display filter is represented as "" */
- *buf++ = '"';
- *buf++ = '"';
- }
+ if (fv->value.bytes->len) {
+ buf = bytes_to_hexstr_punct(buf, fv->value.bytes->data, fv->value.bytes->len, separator);
+ }
+ else {
+ if (rtype == FTREPR_DFILTER) {
+ /* An empty byte array in a display filter is represented as "" */
+ *buf++ = '"';
+ *buf++ = '"';
}
- *buf = '\0';
}
+ *buf = '\0';
}
static void