Use tvb_new_subset_remaining() rather than tvb_new_subset();
Do minir whitespace cleanup. svn path=/trunk/; revision=41366
This commit is contained in:
parent
594b358011
commit
d3cfffd72a
|
@ -204,7 +204,7 @@ dissect_papi(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
|
|||
offset = dissect_papi_debug(tvb, offset, papi_tree);
|
||||
}
|
||||
|
||||
next_tvb = tvb_new_subset(tvb, offset, -1, -1);
|
||||
next_tvb = tvb_new_subset_remaining(tvb, offset);
|
||||
call_dissector(data_handle,next_tvb, pinfo, tree);
|
||||
}
|
||||
|
||||
|
|
|
@ -724,7 +724,7 @@ dissect_nbp(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree) {
|
|||
proto_tree_add_item(nbp_tree, hf_nbp_tid, tvb, offset+1, 1, ENC_BIG_ENDIAN);
|
||||
offset += 2;
|
||||
|
||||
for (i=0; i<count; i++) {
|
||||
for (i = 0; i < count; i++) {
|
||||
proto_tree *node_item,*node_tree;
|
||||
int soffset = offset;
|
||||
|
||||
|
@ -905,7 +905,7 @@ dissect_atp(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree) {
|
|||
}
|
||||
else {
|
||||
/* full packet */
|
||||
new_tvb = tvb_new_subset(tvb, ATP_HDRSIZE -1, -1,- 1);
|
||||
new_tvb = tvb_new_subset_remaining(tvb, ATP_HDRSIZE -1 );
|
||||
}
|
||||
|
||||
if (new_tvb) {
|
||||
|
@ -1515,7 +1515,7 @@ dissect_atp_zip(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
|
|||
ti = proto_tree_add_item(zip_tree, hf_zip_count, tvb, offset, 2, ENC_BIG_ENDIAN);
|
||||
offset += 2;
|
||||
sub_tree = proto_item_add_subtree(ti, ett_zip_zones_list);
|
||||
for (i= 0; i < count; i++) {
|
||||
for (i = 0; i < count; i++) {
|
||||
len = tvb_get_guint8(tvb, offset);
|
||||
proto_tree_add_item(sub_tree, hf_zip_zone_name, tvb, offset, 1,ENC_ASCII|ENC_BIG_ENDIAN);
|
||||
offset += len +1;
|
||||
|
@ -1563,7 +1563,7 @@ dissect_ddp_zip(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
|
|||
ti = proto_tree_add_item(zip_tree, hf_zip_network_count, tvb, offset, 1, ENC_BIG_ENDIAN);
|
||||
offset++;
|
||||
sub_tree = proto_item_add_subtree(ti, ett_zip_network_list);
|
||||
for (i= 0; i < count; i++) {
|
||||
for (i = 0; i < count; i++) {
|
||||
proto_tree_add_item(sub_tree, hf_zip_network, tvb, offset, 2, ENC_BIG_ENDIAN);
|
||||
offset += 2;
|
||||
}
|
||||
|
@ -1599,7 +1599,7 @@ dissect_ddp_zip(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
|
|||
ti = proto_tree_add_item(zip_tree, hf_zip_network_count, tvb, offset, 1, ENC_BIG_ENDIAN);
|
||||
offset++;
|
||||
sub_tree = proto_item_add_subtree(ti, ett_zip_network_list);
|
||||
for (i= 0; i < count; i++) {
|
||||
for (i = 0; i < count; i++) {
|
||||
net = tvb_get_ntohs(tvb, offset);
|
||||
ti = proto_tree_add_text(sub_tree, tvb, offset , 2, "Zone for network : %u", net);
|
||||
net_tree = proto_item_add_subtree(ti, ett_zip_network_list);
|
||||
|
|
Loading…
Reference in New Issue