[PATCH] configure: add --without-api-docs option
[notmuch-archives.git] / 3c / b8cb474a501c8ba56c0be7b04cff563b5055a3
1 Return-Path: <tomi.ollila@iki.fi>\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 4FE3A431FAF\r
6         for <notmuch@notmuchmail.org>; Mon, 17 Dec 2012 08:24:47 -0800 (PST)\r
7 X-Virus-Scanned: Debian amavisd-new at olra.theworths.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 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 fsbrW2HYLNUW for <notmuch@notmuchmail.org>;\r
16         Mon, 17 Dec 2012 08:24:46 -0800 (PST)\r
17 Received: from guru.guru-group.fi (guru.guru-group.fi [46.183.73.34])\r
18         by olra.theworths.org (Postfix) with ESMTP id 6D7CE431FAE\r
19         for <notmuch@notmuchmail.org>; Mon, 17 Dec 2012 08:24:46 -0800 (PST)\r
20 Received: from guru.guru-group.fi (localhost [IPv6:::1])\r
21         by guru.guru-group.fi (Postfix) with ESMTP id 00F69100094;\r
22         Mon, 17 Dec 2012 18:24:39 +0200 (EET)\r
23 From: Tomi Ollila <tomi.ollila@iki.fi>\r
24 To: david@tethera.net, notmuch@notmuchmail.org\r
25 Subject: Re: [PATCH 2/3] tag-utils: use the tag_opt_list_t as talloc context,\r
26         if possible.\r
27 In-Reply-To: <1355716788-2940-3-git-send-email-david@tethera.net>\r
28 References: <1355716788-2940-1-git-send-email-david@tethera.net>\r
29         <1355716788-2940-3-git-send-email-david@tethera.net>\r
30 User-Agent: Notmuch/0.14+116~g29fcdb5 (http://notmuchmail.org) Emacs/24.2.1\r
31         (x86_64-unknown-linux-gnu)\r
32 X-Face: HhBM'cA~<r"^Xv\KRN0P{vn'Y"Kd;zg_y3S[4)KSN~s?O\"QPoL\r
33         $[Xv_BD:i/F$WiEWax}R(MPS`^UaptOGD`*/=@\1lKoVa9tnrg0TW?"r7aRtgk[F\r
34         !)g;OY^,BjTbr)Np:%c_o'jj,Z\r
35 Date: Mon, 17 Dec 2012 18:24:39 +0200\r
36 Message-ID: <m24njkir3s.fsf@guru.guru-group.fi>\r
37 MIME-Version: 1.0\r
38 Content-Type: text/plain\r
39 Cc: David Bremner <bremner@debian.org>\r
40 X-BeenThere: notmuch@notmuchmail.org\r
41 X-Mailman-Version: 2.1.13\r
42 Precedence: list\r
43 List-Id: "Use and development of the notmuch mail system."\r
44         <notmuch.notmuchmail.org>\r
45 List-Unsubscribe: <http://notmuchmail.org/mailman/options/notmuch>,\r
46         <mailto:notmuch-request@notmuchmail.org?subject=unsubscribe>\r
47 List-Archive: <http://notmuchmail.org/pipermail/notmuch>\r
48 List-Post: <mailto:notmuch@notmuchmail.org>\r
49 List-Help: <mailto:notmuch-request@notmuchmail.org?subject=help>\r
50 List-Subscribe: <http://notmuchmail.org/mailman/listinfo/notmuch>,\r
51         <mailto:notmuch-request@notmuchmail.org?subject=subscribe>\r
52 X-List-Received-Date: Mon, 17 Dec 2012 16:24:47 -0000\r
53 \r
54 On Mon, Dec 17 2012, david@tethera.net wrote:\r
55 \r
56 > From: David Bremner <bremner@debian.org>\r
57 >\r
58 > This code is no less correct than the previous version, since it does\r
59 > not make sense for the array to live longer than the wrapping struct.\r
60 >\r
61 > By not relying on the context passed into tag_parse_line, we can allow\r
62 > tag_op_list_t structures to live longer than that context.\r
63 > ---\r
64 \r
65 The whole patch series looks good to me -- just that this comment\r
66 gets a bit over my head...\r
67 \r
68 Tomi\r
69 \r
70 \r
71 >  notmuch-restore.c |    2 +-\r
72 >  tag-util.c        |    9 ++++-----\r
73 >  tag-util.h        |    3 +--\r
74 >  3 files changed, 6 insertions(+), 8 deletions(-)\r
75 >\r
76 > diff --git a/notmuch-restore.c b/notmuch-restore.c\r
77 > index 5a02328..665373f 100644\r
78 > --- a/notmuch-restore.c\r
79 > +++ b/notmuch-restore.c\r
80 > @@ -105,7 +105,7 @@ parse_sup_line (void *ctx, char *line,\r
81 >           tok_len++;\r
82 >       }\r
83 >  \r
84 > -     if (tag_op_list_append (ctx, tag_ops, tok, FALSE))\r
85 > +     if (tag_op_list_append (tag_ops, tok, FALSE))\r
86 >           return -1;\r
87 >      }\r
88 >  \r
89 > diff --git a/tag-util.c b/tag-util.c\r
90 > index eab482f..705b7ba 100644\r
91 > --- a/tag-util.c\r
92 > +++ b/tag-util.c\r
93 > @@ -109,7 +109,7 @@ parse_tag_line (void *ctx, char *line,\r
94 >           goto DONE;\r
95 >       }\r
96 >  \r
97 > -     if (tag_op_list_append (ctx, tag_ops, tag, remove)) {\r
98 > +     if (tag_op_list_append (tag_ops, tag, remove)) {\r
99 >           ret = line_error (TAG_PARSE_OUT_OF_MEMORY, line_for_error,\r
100 >                             "aborting");\r
101 >           goto DONE;\r
102 > @@ -294,7 +294,7 @@ tag_op_list_create (void *ctx)\r
103 >      list->size = TAG_OP_LIST_INITIAL_SIZE;\r
104 >      list->count = 0;\r
105 >  \r
106 > -    list->ops = talloc_array (ctx, tag_operation_t, list->size);\r
107 > +    list->ops = talloc_array (list, tag_operation_t, list->size);\r
108 >      if (list->ops == NULL)\r
109 >       return NULL;\r
110 >  \r
111 > @@ -303,8 +303,7 @@ tag_op_list_create (void *ctx)\r
112 >  \r
113 >  \r
114 >  int\r
115 > -tag_op_list_append (void *ctx,\r
116 > -                 tag_op_list_t *list,\r
117 > +tag_op_list_append (tag_op_list_t *list,\r
118 >                   const char *tag,\r
119 >                   notmuch_bool_t remove)\r
120 >  {\r
121 > @@ -314,7 +313,7 @@ tag_op_list_append (void *ctx,\r
122 >  \r
123 >      if (list->count == list->size) {\r
124 >       list->size *= 2;\r
125 > -     list->ops = talloc_realloc (ctx, list->ops, tag_operation_t,\r
126 > +     list->ops = talloc_realloc (list, list->ops, tag_operation_t,\r
127 >                                   list->size);\r
128 >       if (list->ops == NULL) {\r
129 >           fprintf (stderr, "Out of memory.\n");\r
130 > diff --git a/tag-util.h b/tag-util.h\r
131 > index 99b0fa0..c07bfde 100644\r
132 > --- a/tag-util.h\r
133 > +++ b/tag-util.h\r
134 > @@ -87,8 +87,7 @@ tag_op_list_create (void *ctx);\r
135 >   */\r
136 >  \r
137 >  int\r
138 > -tag_op_list_append (void *ctx,\r
139 > -                 tag_op_list_t *list,\r
140 > +tag_op_list_append (tag_op_list_t *list,\r
141 >                   const char *tag,\r
142 >                   notmuch_bool_t remove);\r
143 >  \r
144 > -- \r
145 > 1.7.10.4\r
146 >\r
147 > _______________________________________________\r
148 > notmuch mailing list\r
149 > notmuch@notmuchmail.org\r
150 > http://notmuchmail.org/mailman/listinfo/notmuch\r