From 08227fce1803b83e0477ef48875f8dba21a99f45 Mon Sep 17 00:00:00 2001 From: Tomi Ollila Date: Fri, 18 May 2012 09:59:27 +0300 Subject: [PATCH] Re: [PATCH 4/6] cli: intialize crypto structure in show and reply --- d6/e715526d2fcd39a9661c3d1fe9cab4edc5424d | 102 ++++++++++++++++++++++ 1 file changed, 102 insertions(+) create mode 100644 d6/e715526d2fcd39a9661c3d1fe9cab4edc5424d diff --git a/d6/e715526d2fcd39a9661c3d1fe9cab4edc5424d b/d6/e715526d2fcd39a9661c3d1fe9cab4edc5424d new file mode 100644 index 000000000..33bbfd518 --- /dev/null +++ b/d6/e715526d2fcd39a9661c3d1fe9cab4edc5424d @@ -0,0 +1,102 @@ +Return-Path: +X-Original-To: notmuch@notmuchmail.org +Delivered-To: notmuch@notmuchmail.org +Received: from localhost (localhost [127.0.0.1]) + by olra.theworths.org (Postfix) with ESMTP id B8BAF431FB6 + for ; Thu, 17 May 2012 23:59:19 -0700 (PDT) +X-Virus-Scanned: Debian amavisd-new at olra.theworths.org +X-Spam-Flag: NO +X-Spam-Score: 0 +X-Spam-Level: +X-Spam-Status: No, score=0 tagged_above=-999 required=5 tests=[none] + autolearn=disabled +Received: from olra.theworths.org ([127.0.0.1]) + by localhost (olra.theworths.org [127.0.0.1]) (amavisd-new, port 10024) + with ESMTP id uBdPgxWwq+Wi for ; + Thu, 17 May 2012 23:59:18 -0700 (PDT) +Received: from guru.guru-group.fi (guru.guru-group.fi [46.183.73.34]) + by olra.theworths.org (Postfix) with ESMTP id 7122A431FAE + for ; Thu, 17 May 2012 23:59:18 -0700 (PDT) +Received: by guru.guru-group.fi (Postfix, from userid 501) + id 3E18D100639; Fri, 18 May 2012 09:59:27 +0300 (EEST) +From: Tomi Ollila +To: Daniel Kahn Gillmor , + Notmuch Mail +Subject: Re: [PATCH 4/6] cli: intialize crypto structure in show and reply +In-Reply-To: <4FB572DA.8040906@fifthhorseman.net> +References: <1337205359-2444-1-git-send-email-jrollins@finestructure.net> + <1337205359-2444-2-git-send-email-jrollins@finestructure.net> + <1337205359-2444-3-git-send-email-jrollins@finestructure.net> + <1337205359-2444-4-git-send-email-jrollins@finestructure.net> + <1337205359-2444-5-git-send-email-jrollins@finestructure.net> + <8762bvi70k.fsf@nikula.org> + <877gwaeve1.fsf@servo.finestructure.net> + + <87aa16daeq.fsf@servo.finestructure.net> + <4FB572DA.8040906@fifthhorseman.net> +User-Agent: Notmuch/0.13~rc1+23~gefd2384 (http://notmuchmail.org) Emacs/23.1.1 + (x86_64-redhat-linux-gnu) +X-Face: HhBM'cA~ +MIME-Version: 1.0 +Content-Type: text/plain; charset=us-ascii +X-BeenThere: notmuch@notmuchmail.org +X-Mailman-Version: 2.1.13 +Precedence: list +List-Id: "Use and development of the notmuch mail system." + +List-Unsubscribe: , + +List-Archive: +List-Post: +List-Help: +List-Subscribe: , + +X-List-Received-Date: Fri, 18 May 2012 06:59:19 -0000 + +On Fri, May 18 2012, Daniel Kahn Gillmor wrote: + +> +> The real tradeoff in this choice is whether we prefer: +> +> a) more compact code to facilitate quick reading by experts +> +> or +> +> b) more verbose code to facilitate comprehension by the non-expert. +> +> I started this discussion leaning strongly toward the (b) perspective. +> But now that i know the relevant bits of the standard, i can sympathize +> with the (a) perspective as well :P +> +> Overall, i think i'm still in the (b) camp. But i think it's more +> important that we don't allow dithering over this issue to prevent the +> inclusion of this patch series, which is a step in the right direction +> for handling S/MIME messages as well as PGP/MIME. + +I also think it is good to see explicit initializations when those aren't +needed but clarifies the code. After all it doesn't generate any extra +code to the target module. Also the &(params->crypto) is good from +clarification point of view. + +Austin's .crypto { ... } initialization looks good & clear; In case there +will be new version of this patch series I'd like to see that used... + +> --dkg +> +> PS gcc's -pedantic argument provides the following warning: +> +> error: ISO C90 forbids specifying subobject to initialize +> +> So we probably want to specify -std=c99 at least to ensure our choice of +> subobject initialization is respected. + +In order to do that id:"cover.1325977940.git.jani@nikula.org" needs to +be applied (and probably rebased). + +> [0] http://www.open-std.org/jtc1/sc22/WG14/www/docs/n1256.pdf + +Tomi -- 2.26.2