aboutsummaryrefslogtreecommitdiffhomepage
path: root/notmuch-reply.c
diff options
context:
space:
mode:
authorGravatar Jameson Graef Rollins <jrollins@finestructure.net>2011-06-08 12:30:07 -0700
committerGravatar David Bremner <bremner@debian.org>2011-10-06 10:12:48 -0300
commitc75410fd81878ccb9f3fa3878507e5650de5fa3f (patch)
tree1375fbf0634456a182412df470877397fd10a30d /notmuch-reply.c
parenta53422fedcfc232b6e4f4bb9cb24a622710dd5d5 (diff)
Fix notmuch-reply to not output "Non-text part:" lines for non-leafnode parts.
These lines are just cruft in this case, and can be removed.
Diffstat (limited to 'notmuch-reply.c')
-rw-r--r--notmuch-reply.c11
1 files changed, 6 insertions, 5 deletions
diff --git a/notmuch-reply.c b/notmuch-reply.c
index f4b1a61b..c500862d 100644
--- a/notmuch-reply.c
+++ b/notmuch-reply.c
@@ -93,7 +93,12 @@ reply_part_content (GMimeObject *part)
GMimeContentType *content_type = g_mime_object_get_content_type (GMIME_OBJECT (part));
GMimeContentDisposition *disposition = g_mime_object_get_content_disposition (part);
- if (g_mime_content_type_is_type (content_type, "text", "*") &&
+ if (g_mime_content_type_is_type (content_type, "multipart", "*") ||
+ g_mime_content_type_is_type (content_type, "message", "rfc822"))
+ {
+ /* Output nothing, since multipart subparts will be handled individually. */
+ }
+ else if (g_mime_content_type_is_type (content_type, "text", "*") &&
!g_mime_content_type_is_type (content_type, "text", "html"))
{
GMimeStream *stream_stdout = NULL, *stream_filter = NULL;
@@ -120,10 +125,6 @@ reply_part_content (GMimeObject *part)
if (stream_stdout)
g_object_unref(stream_stdout);
}
- else if (g_mime_content_type_is_type (content_type, "message", "rfc822"))
- {
- /* Output nothing, since rfc822 subparts will be handled individually. */
- }
else
{
if (disposition &&