projects
/
citadel.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
fd82bea
)
Mimeparser rewrite; fix bug detecting trailing MIME-Boundary
author
Wilfried Goesgens
<dothebart@citadel.org>
Sat, 15 Jan 2011 15:14:16 +0000
(16:14 +0100)
committer
Wilfried Goesgens
<dothebart@citadel.org>
Sat, 15 Jan 2011 15:14:16 +0000
(16:14 +0100)
- when searching for the '--' after the mime boundary to detect whether its the last, we had an off by one. fixed.
libcitadel/lib/mime_parser.c
patch
|
blob
|
history
diff --git
a/libcitadel/lib/mime_parser.c
b/libcitadel/lib/mime_parser.c
index 86905f1ee60fe54cd93cf624937f7de988e8ccef..f2aec777ab1b41774aed4cc5ed946fed9197ab79 100644
(file)
--- a/
libcitadel/lib/mime_parser.c
+++ b/
libcitadel/lib/mime_parser.c
@@
-680,8
+680,8
@@
static void recurseable_mime_parser(char *partnum,
if (next_boundary != NULL) {
/* If we pass out of scope, don't attempt to
* read past the end boundary. */
- if ((*(next_boundary + m->b[startary].len
+ 1
) == '-') &&
- (*(next_boundary + m->b[startary].len +
2
) == '-') ){
+ if ((*(next_boundary + m->b[startary].len) == '-') &&
+ (*(next_boundary + m->b[startary].len +
1
) == '-') ){
ptr = content_end;
}
else {