Re: [PATCH v4 09/16] index encrypted parts when asked.
[notmuch-archives.git] / e1 / d1a858a61a60aa0e727ae77e62945e7fe0b7e5
1 Return-Path: <cworth@cworth.org>\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 4C48E431FC0;\r
6         Fri, 27 Nov 2009 04:47:09 -0800 (PST)\r
7 X-Virus-Scanned: Debian amavisd-new at olra.theworths.org\r
8 Received: from olra.theworths.org ([127.0.0.1])\r
9         by localhost (olra.theworths.org [127.0.0.1]) (amavisd-new, port 10024)\r
10         with ESMTP id hv+HRavk5zwV; Fri, 27 Nov 2009 04:47:08 -0800 (PST)\r
11 Received: from cworth.org (localhost [127.0.0.1])\r
12         by olra.theworths.org (Postfix) with ESMTP id 3DD3A431FAE;\r
13         Fri, 27 Nov 2009 04:47:08 -0800 (PST)\r
14 From: Carl Worth <cworth@cworth.org>\r
15 To: Keith Packard <keithp@keithp.com>, notmuch@notmuchmail.org\r
16 In-Reply-To: <yunvdh1nfwn.fsf@aiko.keithp.com>\r
17 References: <yunvdh1nfwn.fsf@aiko.keithp.com>\r
18 Date: Fri, 27 Nov 2009 04:46:54 -0800\r
19 Message-ID: <87iqcwqgn5.fsf@yoom.home.cworth.org>\r
20 MIME-Version: 1.0\r
21 Content-Type: text/plain; charset=us-ascii\r
22 Subject: Re: [notmuch] _notmuch_message_create_for_message_id makes extra\r
23  call to notmuch_database_find_message\r
24 X-BeenThere: notmuch@notmuchmail.org\r
25 X-Mailman-Version: 2.1.12\r
26 Precedence: list\r
27 List-Id: "Use and development of the notmuch mail system."\r
28         <notmuch.notmuchmail.org>\r
29 List-Unsubscribe: <http://notmuchmail.org/mailman/options/notmuch>,\r
30         <mailto:notmuch-request@notmuchmail.org?subject=unsubscribe>\r
31 List-Archive: <http://notmuchmail.org/pipermail/notmuch>\r
32 List-Post: <mailto:notmuch@notmuchmail.org>\r
33 List-Help: <mailto:notmuch-request@notmuchmail.org?subject=help>\r
34 List-Subscribe: <http://notmuchmail.org/mailman/listinfo/notmuch>,\r
35         <mailto:notmuch-request@notmuchmail.org?subject=subscribe>\r
36 X-List-Received-Date: Fri, 27 Nov 2009 12:47:09 -0000\r
37 \r
38 On Mon, 23 Nov 2009 12:29:44 -0800, Keith Packard <keithp@keithp.com> wrote:\r
39\r
40 > Looking at _notmuch_message_create_for_message_id, the first thing it\r
41 > does is call notmuch_database_find_message, but the returned 'message'\r
42 > is never used. I haven't tried, but I suspect this call could just be\r
43 > removed.\r
44 \r
45 Did the "if" statement immediately afterwards just look like error\r
46 checking? It's not:\r
47 \r
48     message = notmuch_database_find_message (notmuch, message_id);\r
49     if (message)\r
50         return talloc_steal (notmuch, message);\r
51 \r
52 That's "if there's a message is in the database with this message-id,\r
53 return it straight away".\r
54 \r
55 Or am I looking at the wrong bit of code?\r
56 \r
57 -Carl\r