Wireshark-dev: Re: [Wireshark-dev] query proto tree within dissector
From: Jeff Morriss <[email protected]>
Date: Fri, 23 Oct 2009 11:11:56 -0400
[email protected] wrote:

my custom dissector defines some subtrees.

I added custom names for packet types like described here:
-> Example 9.9. Naming the packet types.

Now wireshark shows names for the type-field of packets as expected.

Is there a way to query the proto_tree after definition of subtries ??

proto_tree_add_item(myprot_header_tree, hf_myprot_type, tvb, offset, 2, FALSE);
where hf_myprot_type is the field which adds naming to type-byte of the protocol
Is there a way to do somethin like this:
As far as I know, no.  You probably have to retrieve the value (using 
tvb_get_*()) and store it somewhere.