diff options
author | Anders Broman <anders.broman@ericsson.com> | 2007-08-09 12:17:56 +0000 |
---|---|---|
committer | Anders Broman <anders.broman@ericsson.com> | 2007-08-09 12:17:56 +0000 |
commit | 6c161ff927d7683f8fb8f20486fd5127b48bd0fd (patch) | |
tree | 7cc5518e9ae6580d771506ecba78588f61b1fd7c /epan/dissectors/packet-multipart.c | |
parent | 171efad2b803e57484e2e500e23f994867dfdb86 (diff) |
Packet-imf.c - Offset must be advanced to AFTER CRLF(CRLF).
packet-multipart.c - imf_find_field_end()'s maxlength is last offset in tvb.
svn path=/trunk/; revision=22476
Diffstat (limited to 'epan/dissectors/packet-multipart.c')
-rw-r--r-- | epan/dissectors/packet-multipart.c | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/epan/dissectors/packet-multipart.c b/epan/dissectors/packet-multipart.c index 14ab2627c0..a71b69f295 100644 --- a/epan/dissectors/packet-multipart.c +++ b/epan/dissectors/packet-multipart.c @@ -29,7 +29,7 @@ * * References for "media-type multipart/mixed : * http://www.iana.org/assignments/media-types/index.html - * http://www.rfc-editor.org/rfc/rfc2045.txt + * http://www.ietf.org/rfc/rfc2045.txt?number=2045 * http://www.rfc-editor.org/rfc/rfc2046.txt * http://www.rfc-editor.org/rfc/rfc2047.txt * http://www.rfc-editor.org/rfc/rfc2048.txt @@ -622,8 +622,10 @@ process_body_part(proto_tree *tree, tvbuff_t *tvb, const guint8 *boundary, char *hdr_str; char *header_str; - /* Look for the end of the header (denoted by cr) */ - next_offset = imf_find_field_end(tvb, offset, tvb_length_remaining(tvb, offset), &last_field); + /* Look for the end of the header (denoted by cr) + * 3:d argument to imf_find_field_end() maxlen; must be last offset in the tvb. + */ + next_offset = imf_find_field_end(tvb, offset, tvb_length_remaining(tvb, offset)+offset, &last_field); /* If cr not found, won't have advanced - get out to avoid infinite loop! */ if (next_offset == offset) { break; |