aboutsummaryrefslogtreecommitdiffstats
path: root/epan/dissectors/packet-atm.c
diff options
context:
space:
mode:
authorMichael Mann <mmann78@netscape.net>2016-03-19 20:33:14 -0400
committerMichael Mann <mmann78@netscape.net>2016-03-20 17:38:03 +0000
commit1e60d63c8c6882c8c0bdb00cf6df594e1bb6fccf (patch)
tree4147c4f2bee3b93c250a49fa8ec337072c80e713 /epan/dissectors/packet-atm.c
parent2b2fc64447e5f778d969e6c850e9196d248cbbe1 (diff)
Create call_data_dissector() to call data dissector.
This saves many dissectors the need to find the data dissector and store a handle to it. There were also some that were finding it, but not using it. For others this was the only reason for their handoff function, so it could be eliminated. Change-Id: I5d3f951ee1daa3d30c060d21bd12bbc881a8027b Reviewed-on: https://code.wireshark.org/review/14530 Petri-Dish: Michael Mann <mmann78@netscape.net> Reviewed-by: Michael Mann <mmann78@netscape.net>
Diffstat (limited to 'epan/dissectors/packet-atm.c')
-rw-r--r--epan/dissectors/packet-atm.c8
1 files changed, 3 insertions, 5 deletions
diff --git a/epan/dissectors/packet-atm.c b/epan/dissectors/packet-atm.c
index 2a23ffcb2e..574e54104f 100644
--- a/epan/dissectors/packet-atm.c
+++ b/epan/dissectors/packet-atm.c
@@ -147,7 +147,6 @@ static dissector_handle_t sscop_handle;
static dissector_handle_t ppp_handle;
static dissector_handle_t eth_maybefcs_handle;
static dissector_handle_t ip_handle;
-static dissector_handle_t data_handle;
static gboolean dissect_lanesscop = FALSE;
@@ -709,7 +708,7 @@ dissect_lane(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void *data)
/* Dump it as raw data. */
col_set_str(pinfo->cinfo, COL_INFO, "Unknown LANE traffic type");
next_tvb = tvb_new_subset_remaining(tvb, 0);
- call_dissector(data_handle,next_tvb, pinfo, tree);
+ call_data_dissector(next_tvb, pinfo, tree);
break;
}
return tvb_captured_length(tvb);
@@ -1063,7 +1062,7 @@ dissect_reassembled_pdu(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree,
if (!decoded) {
/* Dump it as raw data. */
- call_dissector(data_handle, next_tvb, pinfo, tree);
+ call_data_dissector(next_tvb, pinfo, tree);
}
}
@@ -1432,7 +1431,7 @@ dissect_atm_cell_payload(tvbuff_t *tvb, int offset, packet_info *pinfo,
default:
next_tvb = tvb_new_subset_remaining(tvb, offset);
- call_dissector(data_handle, next_tvb, pinfo, tree);
+ call_data_dissector(next_tvb, pinfo, tree);
break;
}
}
@@ -2017,7 +2016,6 @@ proto_reg_handoff_atm(void)
ppp_handle = find_dissector_add_dependency("ppp", proto_atm);
eth_maybefcs_handle = find_dissector_add_dependency("eth_maybefcs", proto_atm);
ip_handle = find_dissector_add_dependency("ip", proto_atm);
- data_handle = find_dissector("data");
dissector_add_uint("wtap_encap", WTAP_ENCAP_ATM_PDUS, atm_handle);
dissector_add_uint("atm.aal5.type", TRAF_LANE, create_dissector_handle(dissect_lane, proto_atm_lane));