1 Return-Path: <amdragon@mit.edu>
\r
2 X-Original-To: notmuch@notmuchmail.org
\r
3 Delivered-To: notmuch@notmuchmail.org
\r
4 Received: from localhost (localhost [127.0.0.1])
\r
5 by olra.theworths.org (Postfix) with ESMTP id D78B5431FC0
\r
6 for <notmuch@notmuchmail.org>; Fri, 27 Jul 2012 21:29:25 -0700 (PDT)
\r
7 X-Virus-Scanned: Debian amavisd-new at olra.theworths.org
\r
11 X-Spam-Status: No, score=-0.7 tagged_above=-999 required=5
\r
12 tests=[RCVD_IN_DNSWL_LOW=-0.7] autolearn=disabled
\r
13 Received: from olra.theworths.org ([127.0.0.1])
\r
14 by localhost (olra.theworths.org [127.0.0.1]) (amavisd-new, port 10024)
\r
15 with ESMTP id VCQo-orea2cV for <notmuch@notmuchmail.org>;
\r
16 Fri, 27 Jul 2012 21:29:25 -0700 (PDT)
\r
17 Received: from dmz-mailsec-scanner-5.mit.edu (DMZ-MAILSEC-SCANNER-5.MIT.EDU
\r
19 by olra.theworths.org (Postfix) with ESMTP id 301FE431FAF
\r
20 for <notmuch@notmuchmail.org>; Fri, 27 Jul 2012 21:29:25 -0700 (PDT)
\r
21 X-AuditID: 12074422-b7f1f6d00000090b-4a-50136aa4f98b
\r
22 Received: from mailhub-auth-2.mit.edu ( [18.7.62.36])
\r
23 by dmz-mailsec-scanner-5.mit.edu (Symantec Messaging Gateway) with SMTP
\r
24 id EB.82.02315.4AA63105; Sat, 28 Jul 2012 00:29:24 -0400 (EDT)
\r
25 Received: from outgoing.mit.edu (OUTGOING-AUTH.MIT.EDU [18.7.22.103])
\r
26 by mailhub-auth-2.mit.edu (8.13.8/8.9.2) with ESMTP id q6S4TNxv002939;
\r
27 Sat, 28 Jul 2012 00:29:23 -0400
\r
28 Received: from drake.dyndns.org
\r
29 (209-6-116-242.c3-0.arl-ubr1.sbo-arl.ma.cable.rcn.com
\r
30 [209.6.116.242]) (authenticated bits=0)
\r
31 (User authenticated as amdragon@ATHENA.MIT.EDU)
\r
32 by outgoing.mit.edu (8.13.6/8.12.4) with ESMTP id q6S4TKoL027356
\r
33 (version=TLSv1/SSLv3 cipher=AES256-SHA bits=256 verify=NOT);
\r
34 Sat, 28 Jul 2012 00:29:22 -0400 (EDT)
\r
35 Received: from amthrax by drake.dyndns.org with local (Exim 4.77)
\r
36 (envelope-from <amdragon@mit.edu>)
\r
37 id 1SuyeW-0002Wv-I1; Sat, 28 Jul 2012 00:29:20 -0400
\r
38 From: Austin Clements <amdragon@MIT.EDU>
\r
39 To: notmuch@notmuchmail.org
\r
40 Subject: [PATCH v2 05/13] reply: Create a JSON sprinter
\r
41 Date: Sat, 28 Jul 2012 00:29:06 -0400
\r
42 Message-Id: <1343449754-9010-6-git-send-email-amdragon@mit.edu>
\r
43 X-Mailer: git-send-email 1.7.10
\r
44 In-Reply-To: <1343449754-9010-1-git-send-email-amdragon@mit.edu>
\r
45 References: <1343449754-9010-1-git-send-email-amdragon@mit.edu>
\r
46 X-Brightmail-Tracker:
\r
47 H4sIAAAAAAAAA+NgFrrAIsWRmVeSWpSXmKPExsUixG6norskSzjAYP1CbYu9De2MFqvn8lhc
\r
48 vzmT2eLNynmsDiweO2fdZfdYvGk/m8fhrwtZPJ6tusUcwBLFZZOSmpNZllqkb5fAlXHixjTG
\r
49 glvsFZ/eHmFuYOxg62Lk5JAQMJE4dPQMC4QtJnHh3nqgOBeHkMA+Ronntx6zQDgbGCXmXPzH
\r
50 DOE8YpJ4t341I4Qzl1FiZ+sDsFlsAhoS2/YvZwSxRQSkJXbenc3axcjBwSyQJ/F4rQRIWFjA
\r
51 XGLvibtg61gEVCXmzVvHDmLzCthL3Dq7gQniDHmJp/f7wEZyCjhIbH75gRnEFgKq2T15A+sE
\r
52 Rv4FjAyrGGVTcqt0cxMzc4pTk3WLkxPz8lKLdE31cjNL9FJTSjcxggPORWkH48+DSocYBTgY
\r
53 lXh4T10RChBiTSwrrsw9xCjJwaQkyhsVLhwgxJeUn1KZkVicEV9UmpNafIhRgoNZSYR3pyBQ
\r
54 jjclsbIqtSgfJiXNwaIkznst5aa/kEB6YklqdmpqQWoRTFaGg0NJgnd7JlCjYFFqempFWmZO
\r
55 CUKaiYMTZDgP0HDFLJDhxQWJucWZ6RD5U4yKUuK8j0GaBUASGaV5cL2whPCKURzoFWFeYZB2
\r
56 HmAyget+BTSYCWiwRbQQyOCSRISUVAMj88p654dNby6G3O4S/+iSHnnRcs5KmedX/19Unbnx
\r
57 Z+Rb3tM6u30OScp0GJm7Rwpsfs3zlycp8abbXuuH5pwbBLX+GC++ZHRnPeMeoasqQW9yDs88
\r
58 xG1/7cWDGzp2p15lSm8LuqkTXfTrbv4Rj/+eMT8ez34p38ne+vTEjs9HJP9fWPxB7erHk0os
\r
59 xRmJhlrMRcWJAH7wDFjjAgAA
\r
60 Cc: tomi.ollila@iki.fi
\r
61 X-BeenThere: notmuch@notmuchmail.org
\r
62 X-Mailman-Version: 2.1.13
\r
64 List-Id: "Use and development of the notmuch mail system."
\r
65 <notmuch.notmuchmail.org>
\r
66 List-Unsubscribe: <http://notmuchmail.org/mailman/options/notmuch>,
\r
67 <mailto:notmuch-request@notmuchmail.org?subject=unsubscribe>
\r
68 List-Archive: <http://notmuchmail.org/pipermail/notmuch>
\r
69 List-Post: <mailto:notmuch@notmuchmail.org>
\r
70 List-Help: <mailto:notmuch-request@notmuchmail.org?subject=help>
\r
71 List-Subscribe: <http://notmuchmail.org/mailman/listinfo/notmuch>,
\r
72 <mailto:notmuch-request@notmuchmail.org?subject=subscribe>
\r
73 X-List-Received-Date: Sat, 28 Jul 2012 04:29:26 -0000
\r
76 notmuch-reply.c | 4 ++++
\r
77 1 file changed, 4 insertions(+)
\r
79 diff --git a/notmuch-reply.c b/notmuch-reply.c
\r
80 index de21f3b..e42ba79 100644
\r
81 --- a/notmuch-reply.c
\r
82 +++ b/notmuch-reply.c
\r
85 #include "notmuch-client.h"
\r
86 #include "gmime-filter-headers.h"
\r
87 +#include "sprinter.h"
\r
90 show_reply_headers (GMimeMessage *message)
\r
91 @@ -596,6 +597,7 @@ notmuch_reply_format_json(void *ctx,
\r
92 notmuch_messages_t *messages;
\r
93 notmuch_message_t *message;
\r
97 if (notmuch_query_count_messages (query) != 1) {
\r
98 fprintf (stderr, "Error: search term did not match precisely one message.\n");
\r
99 @@ -611,6 +613,8 @@ notmuch_reply_format_json(void *ctx,
\r
103 + sp = sprinter_json_create (ctx, stdout);
\r
105 /* The headers of the reply message we've created */
\r
106 printf ("{\"reply-headers\": ");
\r
107 format_headers_json (ctx, reply, TRUE);
\r