From 61b2324b4e263709a359938bdfc8e640fbb1f6ba Mon Sep 17 00:00:00 2001 From: Not Zed Date: Wed, 21 Apr 2004 06:55:06 +0000 Subject: use a better test for non-full lines. 2004-04-21 Not Zed * em-inline-filter.c (emif_scan): use a better test for non-full lines. svn path=/trunk/; revision=25554 --- mail/ChangeLog | 3 +++ mail/em-inline-filter.c | 6 ++++-- 2 files changed, 7 insertions(+), 2 deletions(-) (limited to 'mail') diff --git a/mail/ChangeLog b/mail/ChangeLog index 43beeb0e0e..8399808eac 100644 --- a/mail/ChangeLog +++ b/mail/ChangeLog @@ -1,5 +1,8 @@ 2004-04-21 Not Zed + * em-inline-filter.c (emif_scan): use a better test for non-full + lines. + * em-folder-browser.c (emfb_activate): dont desensitise HideDeleted just 'cause we have no folder, it needs to depend on Trash folder only. diff --git a/mail/em-inline-filter.c b/mail/em-inline-filter.c index 1144cff503..9fc4294139 100644 --- a/mail/em-inline-filter.c +++ b/mail/em-inline-filter.c @@ -228,12 +228,14 @@ emif_scan(CamelMimeFilter *f, char *in, size_t len, int final) int len, linelen; /* check the length byte matches the data, if not, output what we have and re-scan this line */ - len = ((start[0] - ' ') & 077) * 4 / 3; + len = ((start[0] - ' ') & 077); linelen = inptr-start-1; while (linelen > 0 && (start[linelen] == '\r' || start[linelen] == '\n')) linelen--; linelen--; - if (linelen != len) { + linelen /= 4; + linelen *= 3; + if (!(len == linelen || len == linelen-1 || len == linelen-2)) { inptr[-1] = '\n'; emif_add_part(emif, data_start, start-data_start); data_start = start; -- cgit