Make TCP segment length a generated field instead of a hidden field.

We should deprecate the use of hidden fields, at least for fields that arei
useful in filters. To make it easier for users to discover and use the fields.

Change the highly useful field for TCP segment payload length from
being a hidden field to be a generated field instead.



svn path=/trunk/; revision=50112
This commit is contained in:
Ronnie Sahlberg 2013-06-22 02:00:03 +00:00
parent e18e933482
commit 707e2ce409

View file

@ -4300,10 +4300,11 @@ dissect_tcp(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
tcph->th_seglen = reported_len - tcph->th_hlen;
tcph->th_have_seglen = TRUE;
if (tree) { /* Add the seglen as an invisible field */
if (tree) {
proto_item *pi;
hidden_item = proto_tree_add_uint(ti, hf_tcp_len, tvb, offset+12, 1, tcph->th_seglen);
PROTO_ITEM_SET_HIDDEN(hidden_item);
pi = proto_tree_add_uint(ti, hf_tcp_len, tvb, offset+12, 1, tcph->th_seglen);
PROTO_ITEM_SET_GENERATED(pi);
}