diff options
author | Graeme Lunt <graeme.lunt@smhs.co.uk> | 2007-07-05 16:19:36 +0000 |
---|---|---|
committer | Graeme Lunt <graeme.lunt@smhs.co.uk> | 2007-07-05 16:19:36 +0000 |
commit | ce458040ac39c8cd5b8971b029b7b4bf5ea16404 (patch) | |
tree | fffa151a8763b9ef09c87dfbb415e77ab8878599 /epan/dissectors/packet-multipart.c | |
parent | 9f5e016fff61dea488905eb9802829748f535104 (diff) |
Allow for leading whitespace in parameters when looking for the boundary.
svn path=/trunk/; revision=22246
Diffstat (limited to 'epan/dissectors/packet-multipart.c')
-rw-r--r-- | epan/dissectors/packet-multipart.c | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/epan/dissectors/packet-multipart.c b/epan/dissectors/packet-multipart.c index dc26248e38..b94f9f007a 100644 --- a/epan/dissectors/packet-multipart.c +++ b/epan/dissectors/packet-multipart.c @@ -328,7 +328,11 @@ get_multipart_info(packet_info *pinfo) * The parameters must contain the boundary string */ p = parameters; - while (*p) { + while (*p) {
+ + while ((*p) && isspace((guchar)*p))
+ p++; /* Skip white space */
+
if (strncasecmp(p, "boundary=", 9) == 0) break; /* Skip to next parameter */ @@ -339,8 +343,7 @@ get_multipart_info(packet_info *pinfo) return NULL; } p++; /* Skip semicolon */ - while ((*p) && isspace((guchar)*p)) - p++; /* Skip white space */ + } start = p + 9; if (start[0] == 0) { |