summaryrefslogtreecommitdiff
path: root/tools/convert_proto_tree_add_text.pl
diff options
context:
space:
mode:
authorMichael Mann <mmann78@netscape.net>2013-07-26 18:30:10 +0000
committerMichael Mann <mmann78@netscape.net>2013-07-26 18:30:10 +0000
commit2675472389982d3ae9c71f6ff7f9936fc61fadb5 (patch)
treebb3046d2b7d5fcf3e90e7bead8019556d90ef07d /tools/convert_proto_tree_add_text.pl
parenta7a2d51fae5ba287c9d79c09a07495a123442c0c (diff)
downloadwireshark-2675472389982d3ae9c71f6ff7f9936fc61fadb5.tar.gz
Add support for common FT_ETHER cases.
Bugfix gauging where the "field text" argument when parsing the proto_tree_add_text call. svn path=/trunk/; revision=50925
Diffstat (limited to 'tools/convert_proto_tree_add_text.pl')
-rwxr-xr-xtools/convert_proto_tree_add_text.pl7
1 files changed, 5 insertions, 2 deletions
diff --git a/tools/convert_proto_tree_add_text.pl b/tools/convert_proto_tree_add_text.pl
index 25b3332a89..3e3ddcb1d2 100755
--- a/tools/convert_proto_tree_add_text.pl
+++ b/tools/convert_proto_tree_add_text.pl
@@ -369,7 +369,8 @@ sub generate_hfs {
if (scalar @args > 5) {
if (($proto_tree_item[6] eq "1") ||
($args[5] =~ /tvb_get_guint8/) ||
- ($args[5] =~ /tvb_bytes_to_str/)) {
+ ($args[5] =~ /tvb_bytes_to_str/) ||
+ ($args[5] =~ /tvb_ether_to_str/)) {
$proto_tree_item[7] = "ENC_NA";
} elsif ($args[5] =~ /tvb_get_ntoh/) {
$proto_tree_item[7] = "ENC_BIG_ENDIAN";
@@ -384,7 +385,7 @@ sub generate_hfs {
}
#Field name
- if (($expert ne "") && (scalar @args > 5)) {
+ if (($expert ne "") || (scalar @args > 5)) {
my @arg_temp = split(/=|:/, $args[4]);
$proto_tree_item[8] = $arg_temp[0];
} else {
@@ -458,6 +459,8 @@ sub generate_hfs {
$proto_tree_item[9] = "FT_STRING";
} elsif ($args[5] =~ /tvb_bytes_to_str/) {
$proto_tree_item[9] = "FT_BYTES";
+ } elsif ($args[5] =~ /tvb_ether_to_str/) {
+ $proto_tree_item[9] = "FT_ETHER";
}
}