unofficial mirror of notmuch@notmuchmail.org
 help / color / mirror / code / Atom feed
* [PATCH] notmuch-show: include Bcc header in json output
@ 2012-09-05 21:40 Michal Nazarewicz
  2012-09-06 14:31 ` Michal Sojka
                   ` (2 more replies)
  0 siblings, 3 replies; 18+ messages in thread
From: Michal Nazarewicz @ 2012-09-05 21:40 UTC (permalink / raw)
  To: notmuch

From: Michal Nazarewicz <mina86@mina86.com>

---
 notmuch-show.c |    7 +++++++
 1 files changed, 7 insertions(+), 0 deletions(-)

Actually, I don't understand why json does not include all the
headers...

diff --git a/notmuch-show.c b/notmuch-show.c
index 3556293..0b7abf1 100644
--- a/notmuch-show.c
+++ b/notmuch-show.c
@@ -233,6 +233,13 @@ format_headers_json (sprinter_t *sp, GMimeMessage *message,
 	sp->string (sp, recipients_string);
     }
 
+    recipients = g_mime_message_get_recipients (message, GMIME_RECIPIENT_TYPE_BCC);
+    recipients_string = internet_address_list_to_string (recipients, 0);
+    if (recipients_string) {
+	sp->map_key (sp, "Bcc");
+	sp->string (sp, recipients_string);
+    }
+
     if (reply) {
 	sp->map_key (sp, "In-reply-to");
 	sp->string (sp, g_mime_object_get_header (GMIME_OBJECT (message), "In-reply-to"));
-- 
1.7.7.3

^ permalink raw reply related	[flat|nested] 18+ messages in thread

end of thread, other threads:[~2012-11-07 14:03 UTC | newest]

Thread overview: 18+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2012-09-05 21:40 [PATCH] notmuch-show: include Bcc header in json output Michal Nazarewicz
2012-09-06 14:31 ` Michal Sojka
2012-09-06 15:16 ` Michal Nazarewicz
2012-09-07 11:52   ` Michal Sojka
2012-09-08 11:29 ` Tomi Ollila
2012-09-10  6:35   ` [PATCHv3] " Michal Nazarewicz
2012-09-10  8:52     ` Tomi Ollila
2012-09-10  9:13       ` Michal Nazarewicz
2012-09-10  9:30         ` Tomi Ollila
2012-09-10  9:41           ` Michal Nazarewicz
2012-10-20 15:58     ` Ethan Glasser-Camp
2012-10-22 23:09     ` David Bremner
2012-10-29 16:08       ` [PATCH] Add NEWS information about Bcc header in JSON output Michal Nazarewicz
2012-10-31 21:40         ` David Bremner
2012-11-01 13:51           ` Michal Nazarewicz
2012-11-07 12:09             ` David Bremner
2012-11-07 13:04               ` Tomi Ollila
2012-11-07 14:03                 ` Michal Nazarewicz

Code repositories for project(s) associated with this public inbox

	https://yhetil.org/notmuch.git/

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).