[evolution] Add CamelDebug to e_mail_parser_parse_sync



commit ca9dfde2c30a211d8760064c541f368def4f1fe6
Author: Dan VrÃtil <dvratil redhat com>
Date:   Wed Jun 27 11:04:32 2012 +0200

    Add CamelDebug to e_mail_parser_parse_sync

 em-format/e-mail-parser.c |   17 +++++++++++++++++
 1 files changed, 17 insertions(+), 0 deletions(-)
---
diff --git a/em-format/e-mail-parser.c b/em-format/e-mail-parser.c
index 5af3d61..d173503 100644
--- a/em-format/e-mail-parser.c
+++ b/em-format/e-mail-parser.c
@@ -308,6 +308,23 @@ e_mail_parser_parse_sync (EMailParser *parser,
 
 	parts_list->list = mail_parser_run (parser, message, cancellable);
 
+	if (camel_debug_start ("emformat:parser")) {
+		GSList *iter;
+
+		printf("%s finished with EMailPartList:\n",
+				G_OBJECT_TYPE_NAME (parser));
+
+		for (iter = parts_list->list; iter; iter = iter->next) {
+			EMailPart *part = iter->data;
+			if (!part) continue;
+			printf("	id: %s | cid: %s | mime_type: %s | is_hidden: %d | is_attachment: %d\n",
+				part->id, part->cid, part->mime_type,
+				part->is_hidden ? 1 : 0, part->is_attachment ? 1 : 0);
+		}
+
+		camel_debug_end ();
+	}
+
 	return parts_list;
 }
 



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]