evolution r35781 - trunk/mail
- From: abharath svn gnome org
- To: svn-commits-list gnome org
- Subject: evolution r35781 - trunk/mail
- Date: Sun, 20 Jul 2008 19:10:47 +0000 (UTC)
Author: abharath
Date: Sun Jul 20 19:10:46 2008
New Revision: 35781
URL: http://svn.gnome.org/viewvc/evolution?rev=35781&view=rev
Log:
Committing on behalf of Milan Crha <mcrha redhat com>
2008-07-09 Milan Crha <mcrha redhat com>
** Fix for bug #269152
* em-format-quote.c: (emfq_format_header):
* em-format-html.c: (efh_format_headers):
Use X-MimeOLE as Mailer header when there's nothing better
available.
Modified:
trunk/mail/ChangeLog
trunk/mail/em-format-html.c
trunk/mail/em-format-quote.c
Modified: trunk/mail/em-format-html.c
==============================================================================
--- trunk/mail/em-format-html.c (original)
+++ trunk/mail/em-format-html.c Sun Jul 20 19:10:46 2008
@@ -1942,15 +1942,30 @@
if (!mailer_shown && mailer && (!g_ascii_strcasecmp (header->name, "X-Mailer") ||
!g_ascii_strcasecmp (header->name, "User-Agent") ||
- !g_ascii_strcasecmp (header->name, "X-Newsreader"))) {
- struct _camel_header_raw xmailer;
+ !g_ascii_strcasecmp (header->name, "X-Newsreader") ||
+ !g_ascii_strcasecmp (header->name, "X-MimeOLE"))) {
+ struct _camel_header_raw xmailer, *use_header = NULL;
+
+ if (!g_ascii_strcasecmp (header->name, "X-MimeOLE")) {
+ for (use_header = header->next; use_header; use_header = use_header->next) {
+ if (!g_ascii_strcasecmp (use_header->name, "X-Mailer") ||
+ !g_ascii_strcasecmp (use_header->name, "User-Agent") ||
+ !g_ascii_strcasecmp (use_header->name, "X-Newsreader")) {
+ /* even we have X-MimeOLE, then use rather the standard one, when available */
+ break;
+ }
+ }
+ }
+
+ if (!use_header)
+ use_header = header;
xmailer.name = "X-Evolution-Mailer";
- xmailer.value = header->value;
+ xmailer.value = use_header->value;
mailer_shown = TRUE;
efh_format_header (emf, stream, part, &xmailer, h->flags, charset);
- if (strstr(header->value, "Evolution"))
+ if (strstr(use_header->value, "Evolution"))
have_icon = TRUE;
} else if (!g_ascii_strcasecmp (header->name, "Face") && !face_decoded) {
char *cp = header->value;
Modified: trunk/mail/em-format-quote.c
==============================================================================
--- trunk/mail/em-format-quote.c (original)
+++ trunk/mail/em-format-quote.c Sun Jul 20 19:10:46 2008
@@ -343,7 +343,9 @@
} else if (!strcmp (name, "X-Evolution-Mailer")) { /* pseudo-header */
if (!(txt = camel_medium_get_header (part, "x-mailer")))
if (!(txt = camel_medium_get_header (part, "user-agent")))
- return;
+ if (!(txt = camel_medium_get_header (part, "x-newsreader")))
+ if (!(txt = camel_medium_get_header (part, "x-mimeole")))
+ return;
txt = value = camel_header_format_ctext (txt, charset);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]