Re: [PATCH 9/9] add has: query prefix to search for specific properties
[notmuch-archives.git] / 94 / cce53ece16d4db293b3fe26e6f645d8f1f0f51
1 Return-Path: <jrollins@servo.finestructure.net>\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 43E35431FD0\r
6         for <notmuch@notmuchmail.org>; Sat, 28 May 2011 14:52:30 -0700 (PDT)\r
7 X-Virus-Scanned: Debian amavisd-new at olra.theworths.org\r
8 X-Spam-Flag: NO\r
9 X-Spam-Score: -1.921\r
10 X-Spam-Level: \r
11 X-Spam-Status: No, score=-1.921 tagged_above=-999 required=5\r
12         tests=[NO_DNS_FOR_FROM=0.379, RCVD_IN_DNSWL_MED=-2.3]\r
13         autolearn=disabled\r
14 Received: from olra.theworths.org ([127.0.0.1])\r
15         by localhost (olra.theworths.org [127.0.0.1]) (amavisd-new, port 10024)\r
16         with ESMTP id iVfYk2N-xuD9 for <notmuch@notmuchmail.org>;\r
17         Sat, 28 May 2011 14:52:29 -0700 (PDT)\r
18 Received: from outgoing-mail.its.caltech.edu (outgoing-mail.its.caltech.edu\r
19         [131.215.239.19])\r
20         by olra.theworths.org (Postfix) with ESMTP id 27BB7429E38\r
21         for <notmuch@notmuchmail.org>; Sat, 28 May 2011 14:52:17 -0700 (PDT)\r
22 Received: from fire-doxen.imss.caltech.edu (localhost [127.0.0.1])\r
23         by fire-doxen-postvirus (Postfix) with ESMTP id A2023328142;\r
24         Sat, 28 May 2011 14:45:49 -0700 (PDT)\r
25 X-Spam-Scanned: at Caltech-IMSS on fire-doxen by amavisd-new\r
26 Received: from servo.finestructure.net (cpe-98-149-172-122.socal.res.rr.com\r
27         [98.149.172.122]) (Authenticated sender: jrollins)\r
28         by fire-doxen-submit (Postfix) with ESMTP id DD2AC2E50E7E;\r
29         Sat, 28 May 2011 14:45:46 -0700 (PDT)\r
30 Received: by servo.finestructure.net (Postfix, from userid 1000)\r
31         id 650699B6; Sat, 28 May 2011 14:52:05 -0700 (PDT)\r
32 From: Jameson Graef Rollins <jrollins@finestructure.net>\r
33 To: Notmuch Mail <notmuch@notmuchmail.org>\r
34 Subject: [PATCH 25/25] Fix stdout stream grabbing in format_part_content_text\r
35 Date: Sat, 28 May 2011 14:52:00 -0700\r
36 Message-Id: <1306619520-25730-26-git-send-email-jrollins@finestructure.net>\r
37 X-Mailer: git-send-email 1.7.4.4\r
38 In-Reply-To: <1306619520-25730-25-git-send-email-jrollins@finestructure.net>\r
39 References: <1306619520-25730-1-git-send-email-jrollins@finestructure.net>\r
40         <1306619520-25730-2-git-send-email-jrollins@finestructure.net>\r
41         <1306619520-25730-3-git-send-email-jrollins@finestructure.net>\r
42         <1306619520-25730-4-git-send-email-jrollins@finestructure.net>\r
43         <1306619520-25730-5-git-send-email-jrollins@finestructure.net>\r
44         <1306619520-25730-6-git-send-email-jrollins@finestructure.net>\r
45         <1306619520-25730-7-git-send-email-jrollins@finestructure.net>\r
46         <1306619520-25730-8-git-send-email-jrollins@finestructure.net>\r
47         <1306619520-25730-9-git-send-email-jrollins@finestructure.net>\r
48         <1306619520-25730-10-git-send-email-jrollins@finestructure.net>\r
49         <1306619520-25730-11-git-send-email-jrollins@finestructure.net>\r
50         <1306619520-25730-12-git-send-email-jrollins@finestructure.net>\r
51         <1306619520-25730-13-git-send-email-jrollins@finestructure.net>\r
52         <1306619520-25730-14-git-send-email-jrollins@finestructure.net>\r
53         <1306619520-25730-15-git-send-email-jrollins@finestructure.net>\r
54         <1306619520-25730-16-git-send-email-jrollins@finestructure.net>\r
55         <1306619520-25730-17-git-send-email-jrollins@finestructure.net>\r
56         <1306619520-25730-18-git-send-email-jrollins@finestructure.net>\r
57         <1306619520-25730-19-git-send-email-jrollins@finestructure.net>\r
58         <1306619520-25730-20-git-send-email-jrollins@finestructure.net>\r
59         <1306619520-25730-21-git-send-email-jrollins@finestructure.net>\r
60         <1306619520-25730-22-git-send-email-jrollins@finestructure.net>\r
61         <1306619520-25730-23-git-send-email-jrollins@finestructure.net>\r
62         <1306619520-25730-24-git-send-email-jrollins@finestructure.net>\r
63         <1306619520-25730-25-git-send-email-jrollins@finestructure.net>\r
64 X-BeenThere: notmuch@notmuchmail.org\r
65 X-Mailman-Version: 2.1.13\r
66 Precedence: list\r
67 List-Id: "Use and development of the notmuch mail system."\r
68         <notmuch.notmuchmail.org>\r
69 List-Unsubscribe: <http://notmuchmail.org/mailman/options/notmuch>,\r
70         <mailto:notmuch-request@notmuchmail.org?subject=unsubscribe>\r
71 List-Archive: <http://notmuchmail.org/pipermail/notmuch>\r
72 List-Post: <mailto:notmuch@notmuchmail.org>\r
73 List-Help: <mailto:notmuch-request@notmuchmail.org?subject=help>\r
74 List-Subscribe: <http://notmuchmail.org/mailman/listinfo/notmuch>,\r
75         <mailto:notmuch-request@notmuchmail.org?subject=subscribe>\r
76 X-List-Received-Date: Sat, 28 May 2011 21:52:30 -0000\r
77 \r
78 The declaration of the GMimeStream pointer to stdout in\r
79 format_part_content_text was somehow preventing subsequent printf\r
80 calls from outputting to stdout if the output was redirected to a\r
81 file.  Scoping the declaration to the actual use of the stream pointer\r
82 works around this problem.\r
83 ---\r
84  notmuch-show.c |    2 +-\r
85  1 files changed, 1 insertions(+), 1 deletions(-)\r
86 \r
87 diff --git a/notmuch-show.c b/notmuch-show.c\r
88 index e90f07e..61c6f49 100644\r
89 --- a/notmuch-show.c\r
90 +++ b/notmuch-show.c\r
91 @@ -447,7 +447,6 @@ format_part_content_text (GMimeObject *part)\r
92  {\r
93      GMimeContentDisposition *disposition = g_mime_object_get_content_disposition (part);\r
94      GMimeContentType *content_type = g_mime_object_get_content_type (GMIME_OBJECT (part));\r
95 -    GMimeStream *stream_stdout = g_mime_stream_file_new (stdout);\r
96  \r
97      printf (", Content-type: %s\n", g_mime_content_type_to_string (content_type));\r
98  \r
99 @@ -462,6 +461,7 @@ format_part_content_text (GMimeObject *part)\r
100      if (g_mime_content_type_is_type (content_type, "text", "*") &&\r
101         !g_mime_content_type_is_type (content_type, "text", "html"))\r
102      {\r
103 +       GMimeStream *stream_stdout = g_mime_stream_file_new (stdout);\r
104         g_mime_stream_file_set_owner (GMIME_STREAM_FILE (stream_stdout), FALSE);\r
105         show_part_content (part, stream_stdout);\r
106         g_object_unref(stream_stdout);\r
107 -- \r
108 1.7.4.4\r
109 \r