Re: [PATCH v4 01/16] add util/search-path.{c, h} to test for executables in $PATH
[notmuch-archives.git] / 57 / e990e5491f660154bf6f536abd49c2bc24528a
1 Return-Path: <dkg@fifthhorseman.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 arlo.cworth.org (Postfix) with ESMTP id 9A00B6DE1B17\r
6  for <notmuch@notmuchmail.org>; Sun, 31 Jan 2016 12:40:13 -0800 (PST)\r
7 X-Virus-Scanned: Debian amavisd-new at cworth.org\r
8 X-Spam-Flag: NO\r
9 X-Spam-Score: 0\r
10 X-Spam-Level: \r
11 X-Spam-Status: No, score=0 tagged_above=-999 required=5 tests=[none]\r
12  autolearn=disabled\r
13 Received: from arlo.cworth.org ([127.0.0.1])\r
14  by localhost (arlo.cworth.org [127.0.0.1]) (amavisd-new, port 10024)\r
15  with ESMTP id uigHvZiJDRaC for <notmuch@notmuchmail.org>;\r
16  Sun, 31 Jan 2016 12:40:12 -0800 (PST)\r
17 Received: from che.mayfirst.org (che.mayfirst.org [209.234.253.108])\r
18  by arlo.cworth.org (Postfix) with ESMTP id E77AD6DE1410\r
19  for <notmuch@notmuchmail.org>; Sun, 31 Jan 2016 12:40:08 -0800 (PST)\r
20 Received: from fifthhorseman.net (ip-64-134-185-108.public.wayport.net\r
21  [64.134.185.108])\r
22  by che.mayfirst.org (Postfix) with ESMTPSA id 3A9DDF99A\r
23  for <notmuch@notmuchmail.org>; Sun, 31 Jan 2016 15:40:06 -0500 (EST)\r
24 Received: by fifthhorseman.net (Postfix, from userid 1000)\r
25  id 3D17F20553; Sun, 31 Jan 2016 15:40:06 -0500 (EST)\r
26 From: Daniel Kahn Gillmor <dkg@fifthhorseman.net>\r
27 To: Notmuch Mail <notmuch@notmuchmail.org>\r
28 Subject: [PATCH v3 05/16] Use a blank _notmuch_crypto to choose the default\r
29  gpg_path\r
30 Date: Sun, 31 Jan 2016 15:39:50 -0500\r
31 Message-Id: <1454272801-23623-6-git-send-email-dkg@fifthhorseman.net>\r
32 X-Mailer: git-send-email 2.7.0.rc3\r
33 In-Reply-To: <1454272801-23623-1-git-send-email-dkg@fifthhorseman.net>\r
34 References: <1454272801-23623-1-git-send-email-dkg@fifthhorseman.net>\r
35 X-BeenThere: notmuch@notmuchmail.org\r
36 X-Mailman-Version: 2.1.20\r
37 Precedence: list\r
38 List-Id: "Use and development of the notmuch mail system."\r
39  <notmuch.notmuchmail.org>\r
40 List-Unsubscribe: <https://notmuchmail.org/mailman/options/notmuch>,\r
41  <mailto:notmuch-request@notmuchmail.org?subject=unsubscribe>\r
42 List-Archive: <http://notmuchmail.org/pipermail/notmuch/>\r
43 List-Post: <mailto:notmuch@notmuchmail.org>\r
44 List-Help: <mailto:notmuch-request@notmuchmail.org?subject=help>\r
45 List-Subscribe: <https://notmuchmail.org/mailman/listinfo/notmuch>,\r
46  <mailto:notmuch-request@notmuchmail.org?subject=subscribe>\r
47 X-List-Received-Date: Sun, 31 Jan 2016 20:40:13 -0000\r
48 \r
49 This way we're only choosing a default in one place.\r
50 ---\r
51  notmuch-config.c | 3 ++-\r
52  1 file changed, 2 insertions(+), 1 deletion(-)\r
53 \r
54 diff --git a/notmuch-config.c b/notmuch-config.c\r
55 index d252bb2..7cd19a7 100644\r
56 --- a/notmuch-config.c\r
57 +++ b/notmuch-config.c\r
58 @@ -418,7 +418,8 @@ notmuch_config_open (void *ctx,\r
59      }\r
60  \r
61      if (notmuch_config_get_crypto_gpg_path (config) == NULL) {\r
62 -       notmuch_config_set_crypto_gpg_path (config, "gpg");\r
63 +       _notmuch_crypto_t crypto = { .gpg_path = NULL };\r
64 +       notmuch_config_set_crypto_gpg_path (config, _notmuch_crypto_get_gpg_path (&crypto));\r
65      }\r
66      \r
67      /* Whenever we know of configuration sections that don't appear in\r
68 -- \r
69 2.7.0.rc3\r
70 \r