[gmime] Fix for bug #606875
- From: Jeffrey Stedfast <fejj src gnome org>
- To: svn-commits-list gnome org
- Cc:
- Subject: [gmime] Fix for bug #606875
- Date: Sat, 30 Jan 2010 17:25:00 +0000 (UTC)
commit d2d5a2b4e1d0d6d8f4b44ca5396c6472ce8fdf92
Author: Jeffrey Stedfast <fejj gnome org>
Date: Tue Jan 19 10:36:27 2010 -0500
Fix for bug #606875
2010-01-17 Jeffrey Stedfast <fejj novell com>
* gmime/gmime-filter-crlf.c (filter_filter): Fixed bug #606875
* by
not trying to skip multiple characters per pass thru the loop
when
encountering the first '.' of a possible '..' sequence.
ChangeLog | 6 ++++++
gmime/gmime-filter-crlf.c | 6 +++---
2 files changed, 9 insertions(+), 3 deletions(-)
---
diff --git a/ChangeLog b/ChangeLog
index f095852..a880764 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,9 @@
+2010-01-17 Jeffrey Stedfast <fejj novell com>
+
+ * gmime/gmime-filter-crlf.c (filter_filter): Fixed bug #606875 by
+ not trying to skip multiple characters per pass thru the loop when
+ encountering the first '.' of a possible '..' sequence.
+
2010-01-12 Jeffrey Stedfast <fejj novell com>
* gmime/gmime-utils.c (g_mime_utils_decode_8bit): Make sure to
diff --git a/gmime/gmime-filter-crlf.c b/gmime/gmime-filter-crlf.c
index 4467c3d..13231e2 100644
--- a/gmime/gmime-filter-crlf.c
+++ b/gmime/gmime-filter-crlf.c
@@ -151,6 +151,7 @@ filter_filter (GMimeFilter *filter, char *inbuf, size_t inlen, size_t prespace,
outptr = filter->outbuf;
while (inptr < inend) {
if (*inptr == '\r') {
+ crlf->saw_dot = FALSE;
crlf->saw_cr = TRUE;
} else {
if (crlf->saw_cr) {
@@ -164,14 +165,13 @@ filter_filter (GMimeFilter *filter, char *inbuf, size_t inlen, size_t prespace,
*outptr++ = '\r';
}
- *outptr++ = *inptr;
+ if (!(crlf->dots && crlf->saw_dot && *inptr == '.'))
+ *outptr++ = *inptr;
}
if (crlf->dots && *inptr == '.') {
if (crlf->saw_lf) {
crlf->saw_dot = TRUE;
- crlf->saw_lf = FALSE;
- inptr++;
} else if (crlf->saw_dot) {
crlf->saw_dot = FALSE;
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]