diff options
author | Michael Mann <mmann78@netscape.net> | 2015-11-08 18:56:41 -0500 |
---|---|---|
committer | Michael Mann <mmann78@netscape.net> | 2015-11-09 15:59:28 +0000 |
commit | 8f529628338f20948e80835076b7b18f6d48c6cf (patch) | |
tree | 8e747dfed7b01759467b622c070e784d5f7c21ab /epan/dissectors/packet-wai.c | |
parent | 51f59e1655ed68b6a01871be111042f6d4787eaa (diff) |
Convert some "ethertype" subdissectors to "new" style.
Change-Id: I93c001e78f9365300d393bac6714535f454c6515
Reviewed-on: https://code.wireshark.org/review/11647
Reviewed-by: Michael Mann <mmann78@netscape.net>
Diffstat (limited to 'epan/dissectors/packet-wai.c')
-rw-r--r-- | epan/dissectors/packet-wai.c | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/epan/dissectors/packet-wai.c b/epan/dissectors/packet-wai.c index 8d68d55077..efcbef7e48 100644 --- a/epan/dissectors/packet-wai.c +++ b/epan/dissectors/packet-wai.c @@ -854,8 +854,8 @@ dissect_wai_data(tvbuff_t *tvb, proto_tree *tree, guint8 subtype, guint16 lenx) } } -static void -dissect_wai(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree) +static int +dissect_wai(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void* data _U_) { /* Format of WAPI protocol packet in WAI authentication system @@ -886,7 +886,7 @@ Figure 18 from [ref:1] /* quick sanity check */ if ((length != tvb_reported_length (tvb)-WAI_MESSAGE_LENGTH) || (subtype > WAI_SUB_MULTICAST_ANNOUNCE_RESP)) { - return; + return 0; } col_set_str(pinfo->cinfo, COL_PROTOCOL, "WAI"); @@ -965,6 +965,7 @@ Figure 18 from [ref:1] } } + return tvb_captured_length(tvb); } static void wai_reassemble_init (void) @@ -1373,7 +1374,7 @@ proto_register_wai(void) proto_register_field_array(proto_wai, hf, array_length(hf)); proto_register_subtree_array(ett, array_length(ett)); - wai_handle = register_dissector("wai", dissect_wai, proto_wai); + wai_handle = new_register_dissector("wai", dissect_wai, proto_wai); } void |