From d56671bc8fd009f709645f1494466ee23e5b78de Mon Sep 17 00:00:00 2001 From: David Bremner Date: Tue, 26 Apr 2016 16:40:07 +2100 Subject: [PATCH] RE: notmuch-0.21 bug report --- 79/dbfcc258d0dcb7bd3deadbfd87f91441bde3d7 | 75 +++++++++++++++++++++++ 1 file changed, 75 insertions(+) create mode 100644 79/dbfcc258d0dcb7bd3deadbfd87f91441bde3d7 diff --git a/79/dbfcc258d0dcb7bd3deadbfd87f91441bde3d7 b/79/dbfcc258d0dcb7bd3deadbfd87f91441bde3d7 new file mode 100644 index 000000000..ec8afc264 --- /dev/null +++ b/79/dbfcc258d0dcb7bd3deadbfd87f91441bde3d7 @@ -0,0 +1,75 @@ +Return-Path: +X-Original-To: notmuch@notmuchmail.org +Delivered-To: notmuch@notmuchmail.org +Received: from localhost (localhost [127.0.0.1]) + by arlo.cworth.org (Postfix) with ESMTP id 26E626DE00C9 + for ; Mon, 25 Apr 2016 12:40:18 -0700 (PDT) +X-Virus-Scanned: Debian amavisd-new at cworth.org +X-Spam-Flag: NO +X-Spam-Score: -0.016 +X-Spam-Level: +X-Spam-Status: No, score=-0.016 tagged_above=-999 required=5 + tests=[AWL=-0.005, SPF_PASS=-0.001, T_RP_MATCHES_RCVD=-0.01] + autolearn=disabled +Received: from arlo.cworth.org ([127.0.0.1]) + by localhost (arlo.cworth.org [127.0.0.1]) (amavisd-new, port 10024) + with ESMTP id kWqQcrXqOwEo for ; + Mon, 25 Apr 2016 12:40:10 -0700 (PDT) +Received: from fethera.tethera.net (fethera.tethera.net [198.245.60.197]) + by arlo.cworth.org (Postfix) with ESMTPS id 5A6106DE00DF + for ; Mon, 25 Apr 2016 12:40:09 -0700 (PDT) +Received: from remotemail by fethera.tethera.net with local (Exim 4.84) + (envelope-from ) + id 1aumMi-0002nX-8I; Mon, 25 Apr 2016 15:40:16 -0400 +Received: (nullmailer pid 6093 invoked by uid 1000); + Mon, 25 Apr 2016 19:40:07 -0000 +From: David Bremner +To: David Binderman , + "notmuch@notmuchmail.org" +Subject: RE: notmuch-0.21 bug report +In-Reply-To: +References: + <87wpnlbllb.fsf@zancas.localnet> + +User-Agent: Notmuch/0.21+99~gd93d377 (http://notmuchmail.org) Emacs/24.5.1 + (x86_64-pc-linux-gnu) +Date: Mon, 25 Apr 2016 16:40:07 -0300 +Message-ID: <87shy9bhpk.fsf@zancas.localnet> +MIME-Version: 1.0 +Content-Type: text/plain +X-BeenThere: notmuch@notmuchmail.org +X-Mailman-Version: 2.1.20 +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: Mon, 25 Apr 2016 19:40:18 -0000 + +David Binderman writes: + +> Hello there, +> +> ---------------------------------------- +>> Hi David; +>> +>> Thanks for the report. fclose doesn't really make sense here; +> +> Surprising. There is a call to fclose for the success return, +> so I just assumed that one would also be required for the error return. +> + +Ah OK, I thought the fclose referred to the notmuch database, but it +refers to the input file. So yes, there is techically a resource leakage +here, but I'm not sure how important it is, since these returns are part +of program shutdown. Is there any harm in having FILEs open for read +when a program shuts down? On the other hand, I guess it would only take +5 or 6 added lines of code if someone wanted to add our usual "goto +DONE" path + +d -- 2.26.2