diff options
author | Ronnie Sahlberg <ronnie_sahlberg@ozemail.com.au> | 2006-04-02 23:24:00 +0000 |
---|---|---|
committer | Ronnie Sahlberg <ronnie_sahlberg@ozemail.com.au> | 2006-04-02 23:24:00 +0000 |
commit | 2376539aabf32cf1b61f3c9f53342467674f84b6 (patch) | |
tree | 080b05f5db69bf585c4d52434662bae2e029a838 /epan/dissectors/packet-nfs.c | |
parent | 695b605cbb8b14499a44658739e418305ccd66c3 (diff) |
the hash,name,fullname of an nfs filehandle are all
generated items
mark them as generated items in the dissect pane
svn path=/trunk/; revision=17785
Diffstat (limited to 'epan/dissectors/packet-nfs.c')
-rw-r--r-- | epan/dissectors/packet-nfs.c | 19 |
1 files changed, 13 insertions, 6 deletions
diff --git a/epan/dissectors/packet-nfs.c b/epan/dissectors/packet-nfs.c index b9017d7ee1..25b35b5a34 100644 --- a/epan/dissectors/packet-nfs.c +++ b/epan/dissectors/packet-nfs.c @@ -789,21 +789,26 @@ nfs_name_snoop_fh(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int fh_of /* if we know the mapping, print the filename */ if(nns){ + proto_item *fh_item; + if(hidden){ - proto_tree_add_string_hidden(tree, hf_nfs_name, tvb, + fh_item=proto_tree_add_string_hidden(tree, hf_nfs_name, tvb, fh_offset, 0, nns->name); }else { - proto_tree_add_string_format(tree, hf_nfs_name, tvb, + fh_item=proto_tree_add_string_format(tree, hf_nfs_name, tvb, fh_offset, 0, nns->name, "Name: %s", nns->name); } + PROTO_ITEM_SET_GENERATED(fh_item); + if(nns->full_name){ if(hidden){ - proto_tree_add_string_hidden(tree, hf_nfs_full_name, tvb, + fh_item=proto_tree_add_string_hidden(tree, hf_nfs_full_name, tvb, fh_offset, 0, nns->name); } else { - proto_tree_add_string_format(tree, hf_nfs_full_name, tvb, + fh_item=proto_tree_add_string_format(tree, hf_nfs_full_name, tvb, fh_offset, 0, nns->name, "Full Name: %s", nns->full_name); } + PROTO_ITEM_SET_GENERATED(fh_item); } } } @@ -1434,6 +1439,7 @@ dissect_fhandle_data(tvbuff_t *tvb, int offset, packet_info *pinfo, { guint32 fhhash; guint32 i; + proto_item *fh_item; for(fhhash=0,i=0;i<(fhlen-3);i+=4){ guint32 val; @@ -1442,12 +1448,13 @@ dissect_fhandle_data(tvbuff_t *tvb, int offset, packet_info *pinfo, fhhash += val; } if(hidden){ - proto_tree_add_uint_hidden(tree, hf_nfs_fh_hash, tvb, offset, + fh_item=proto_tree_add_uint_hidden(tree, hf_nfs_fh_hash, tvb, offset, fhlen, fhhash); } else { - proto_tree_add_uint(tree, hf_nfs_fh_hash, tvb, offset, + fh_item=proto_tree_add_uint(tree, hf_nfs_fh_hash, tvb, offset, fhlen, fhhash); } + PROTO_ITEM_SET_GENERATED(fh_item); if(hash){ *hash=fhhash; } |