diff options
author | Michael Mann <mmann78@netscape.net> | 2013-11-02 13:05:58 +0000 |
---|---|---|
committer | Michael Mann <mmann78@netscape.net> | 2013-11-02 13:05:58 +0000 |
commit | 872f3efeca821b9bf41152c1e962a10bbd13374d (patch) | |
tree | 5e0db679a4f57c7c7731fdfd77a404a9098bb75a /epan/dissectors/packet-multipart.c | |
parent | 26105b7739e8cf7bdefa6549155dfe62419d07ba (diff) |
Prep a few more dissectors to receive their string data through dissector data.
svn path=/trunk/; revision=53045
Diffstat (limited to 'epan/dissectors/packet-multipart.c')
-rw-r--r-- | epan/dissectors/packet-multipart.c | 13 |
1 files changed, 6 insertions, 7 deletions
diff --git a/epan/dissectors/packet-multipart.c b/epan/dissectors/packet-multipart.c index 7baffacf4e..a1794c7181 100644 --- a/epan/dissectors/packet-multipart.c +++ b/epan/dissectors/packet-multipart.c @@ -797,8 +797,7 @@ process_body_part(proto_tree *tree, tvbuff_t *tvb, const guint8 *boundary, * Call this method to actually dissect the multipart body. * NOTE - Only do so if a boundary string has been found! */ -static void dissect_multipart(tvbuff_t *tvb, packet_info *pinfo, - proto_tree *tree) +static int dissect_multipart(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void* data) { proto_tree *subtree = NULL; proto_item *ti = NULL; @@ -816,7 +815,7 @@ static void dissect_multipart(tvbuff_t *tvb, packet_info *pinfo, "The multipart dissector could not find " "the required boundary parameter."); call_dissector(data_handle, tvb, pinfo, tree); - return; + return tvb_length(tvb); } boundary = (guint8 *)m_info->boundary; boundary_len = m_info->boundary_length; @@ -853,7 +852,7 @@ static void dissect_multipart(tvbuff_t *tvb, packet_info *pinfo, call_dissector(data_handle, tvb, pinfo, subtree); /* Clean up the dynamically allocated memory */ cleanup_multipart_info(m_info); - return; + return tvb_length(tvb); } /* * Process the encapsulated bodies @@ -864,7 +863,7 @@ static void dissect_multipart(tvbuff_t *tvb, packet_info *pinfo, if (header_start == -1) { /* Clean up the dynamically allocated memory */ cleanup_multipart_info(m_info); - return; + return tvb_length(tvb); } } /* @@ -877,7 +876,7 @@ static void dissect_multipart(tvbuff_t *tvb, packet_info *pinfo, } /* Clean up the dynamically allocated memory */ cleanup_multipart_info(m_info); - return; + return tvb_length(tvb); } /* Returns index of method in multipart_headers */ @@ -1059,7 +1058,7 @@ proto_reg_handoff_multipart(void) /* * Handle for multipart dissection */ - multipart_handle = create_dissector_handle( + multipart_handle = new_create_dissector_handle( dissect_multipart, proto_multipart); dissector_add_string("media_type", |