aboutsummaryrefslogtreecommitdiffstats
path: root/epan/dissectors/packet-zbee-zcl-misc.c
diff options
context:
space:
mode:
authorPaul Zander <p.j.zander@lighting.com>2018-03-07 09:09:35 +0100
committerAlexis La Goutte <alexis.lagoutte@gmail.com>2018-03-09 12:52:03 +0000
commit1ac90d5254e9e303196c100039b7dd26d23841d1 (patch)
treecd20ede160d51078dd74b02421d42027983f8301 /epan/dissectors/packet-zbee-zcl-misc.c
parent446d9486ae897692fb3e02e90501e38790ac37c8 (diff)
Register and initialize the ZCL clusters in a uniform way.
The cluster registration and initialisation is done in the functions 'proto_reg_handoff_zbee_zcl_XXX'. In these functions the 1st step was to register the dissector. Then the cluster was initialised via the function 'zbee_zcl_init_cluster'. In this patch the registration and initialisation is now done by the function 'zbee_zcl_init_cluster'. In this way we have a more uniform way of registration. Change-Id: If865d904ea51c299a48e5c0004f3f280b7479d49 Reviewed-on: https://code.wireshark.org/review/26325 Petri-Dish: Alexis La Goutte <alexis.lagoutte@gmail.com> Tested-by: Petri Dish Buildbot Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
Diffstat (limited to 'epan/dissectors/packet-zbee-zcl-misc.c')
-rw-r--r--epan/dissectors/packet-zbee-zcl-misc.c18
1 files changed, 4 insertions, 14 deletions
diff --git a/epan/dissectors/packet-zbee-zcl-misc.c b/epan/dissectors/packet-zbee-zcl-misc.c
index 13907105a5..2e277f130f 100644
--- a/epan/dissectors/packet-zbee-zcl-misc.c
+++ b/epan/dissectors/packet-zbee-zcl-misc.c
@@ -565,13 +565,8 @@ proto_register_zbee_zcl_thermostat(void)
void
proto_reg_handoff_zbee_zcl_thermostat(void)
{
- dissector_handle_t thermostat_handle;
-
- /* Register our dissector with the ZigBee application dissectors. */
- thermostat_handle = find_dissector(ZBEE_PROTOABBREV_ZCL_THERMOSTAT);
- dissector_add_uint("zbee.zcl.cluster", ZBEE_ZCL_CID_THERMOSTAT, thermostat_handle);
-
- zbee_zcl_init_cluster( proto_zbee_zcl_thermostat,
+ zbee_zcl_init_cluster( ZBEE_PROTOABBREV_ZCL_THERMOSTAT,
+ proto_zbee_zcl_thermostat,
ett_zbee_zcl_thermostat,
ZBEE_ZCL_CID_THERMOSTAT,
hf_zbee_zcl_thermostat_attr_id,
@@ -909,13 +904,8 @@ dissect_zcl_ias_zone_attr_data(proto_tree *tree, tvbuff_t *tvb, guint *offset, g
void
proto_reg_handoff_zbee_zcl_ias_zone(void)
{
- dissector_handle_t zone_handle;
-
- /* Register our dissector with the ZigBee application dissectors. */
- zone_handle = find_dissector(ZBEE_PROTOABBREV_ZCL_IAS_ZONE);
- dissector_add_uint("zbee.zcl.cluster", ZBEE_ZCL_CID_IAS_ZONE, zone_handle);
-
- zbee_zcl_init_cluster( proto_zbee_zcl_ias_zone,
+ zbee_zcl_init_cluster( ZBEE_PROTOABBREV_ZCL_IAS_ZONE,
+ proto_zbee_zcl_ias_zone,
ett_zbee_zcl_ias_zone,
ZBEE_ZCL_CID_IAS_ZONE,
hf_zbee_zcl_ias_zone_attr_id,