[evolution/webkit: 112/171] Parse too big emails as attachments
- From: Dan VrÃtil <dvratil src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [evolution/webkit: 112/171] Parse too big emails as attachments
- Date: Fri, 24 Feb 2012 12:43:53 +0000 (UTC)
commit d504a522d5dab2b1e0bdf90f42c77406ef3f6c45
Author: Dan VrÃtil <dvratil redhat com>
Date: Mon Jan 9 15:02:36 2012 +0100
Parse too big emails as attachments
em-format/em-format.c | 14 ++++++++++++--
1 files changed, 12 insertions(+), 2 deletions(-)
---
diff --git a/em-format/em-format.c b/em-format/em-format.c
index ed9a5bb..0498d0c 100644
--- a/em-format/em-format.c
+++ b/em-format/em-format.c
@@ -372,7 +372,6 @@ emf_parse_multipart_alternative (EMFormat *emf,
CamelStream *null_stream;
gchar *mime_type;
gsize content_size;
- GByteArray *ba;
if (g_cancellable_is_cancelled (cancellable))
return;
@@ -2181,7 +2180,18 @@ em_format_format_text (EMFormat *emf,
mem_stream, (CamelStream *) stream, cancellable, NULL);
camel_stream_flush ((CamelStream *) mem_stream, cancellable, NULL);
} else {
- /* FIXME WEBKIT */
+ /* Parse it as an attachment */
+ CamelMimePart *part = camel_mime_part_new ();
+ EMFormatParserInfo info = { 0 };
+ GString *part_id = g_string_new (".attachment");
+ camel_medium_set_content ((CamelMedium *) part, dw);
+
+ info.is_attachment = TRUE;
+ em_format_parse_part_as (emf, part, part_id, &info,
+ "x-evolution/message/attachment", cancellable);
+
+ g_string_free (part_id, TRUE);
+ g_object_unref (part);
}
if (windows)
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]