From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on dcvr.yhbt.net X-Spam-Level: X-Spam-Status: No, score=-3.7 required=3.0 tests=AWL,BAYES_00,DKIM_INVALID, DKIM_SIGNED,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI, RCVD_IN_DNSWL_MED,RCVD_IN_MSPIKE_H4,RCVD_IN_MSPIKE_WL,SPF_HELO_NONE, SPF_PASS shortcircuit=no autolearn=ham autolearn_force=no version=3.4.2 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dcvr.yhbt.net (Postfix) with ESMTPS id 9EF1A1F55B for ; Tue, 26 May 2020 08:21:58 +0000 (UTC) Received: from localhost ([::1]:44922 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jdUqT-0001lw-HB for normalperson@yhbt.net; Tue, 26 May 2020 04:21:57 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:47860) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jdUmv-0003cO-UU for bug-gnulib@gnu.org; Tue, 26 May 2020 04:18:17 -0400 Received: from mo6-p00-ob.smtp.rzone.de ([2a01:238:20a:202:5300::1]:13849) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jdUmt-00070z-RR; Tue, 26 May 2020 04:18:17 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; t=1590481091; s=strato-dkim-0002; d=clisp.org; h=References:In-Reply-To:Message-ID:Date:Subject:Cc:To:From: X-RZG-CLASS-ID:X-RZG-AUTH:From:Subject:Sender; bh=60+Lqn8inEBcI6jxFmZWt0ZnA0OiW6WfpCB6Ll7HnFA=; b=Pvvs+aWDUKC++3tDauMkVy6LxKnD/8mTeKk3P2elu78RVXUaOuOaCZIOZaovdx7gI4 q6CUvE8y1KwD7wK1p9RYGdmppeuL9aBRGTOodrgPEZe5M11w/lF+TW2SAVRuL1f5/pBr Y5Agtw5Lz/xbYcbRDw7+LPscX6xNemvC2q5rcr3qnMsSY+78tF9alyGQ2lIM0/fB9E4H M9q4B4jTztpOoO/vc/X662F0dYEmFY62PyZoIPPD8I51vz2kAQKJmwVI9s1a74xtQM+7 /ULAyTQec/FBEtSzLs20Sprm2DUmxT+37mS/sJ1ha1eYyFhFXpP09u1k8CVDYmK0Rk/J msQA== X-RZG-AUTH: ":Ln4Re0+Ic/6oZXR1YgKryK8brlshOcZlIWs+iCP5vnk6shH+AHjwLuWOH6fzxfs=" X-RZG-CLASS-ID: mo00 Received: from bruno.haible.de by smtp.strato.de (RZmta 46.7.0 DYNA|AUTH) with ESMTPSA id x0bd30w4Q8IAaC5 (using TLSv1 with cipher ECDHE-RSA-AES256-SHA (curve X9_62_prime256v1 with 256 ECDH bits, eq. 3072 bits RSA)) (Client did not present a certificate); Tue, 26 May 2020 10:18:10 +0200 (CEST) From: Bruno Haible To: Daiki Ueno Subject: Re: portability of fopen and 'e' (O_CLOEXEC) flag Date: Tue, 26 May 2020 10:18:09 +0200 Message-ID: <2318672.ckYohbHQXy@omega> User-Agent: KMail/5.1.3 (Linux/4.4.0-177-generic; KDE/5.18.0; x86_64; ; ) In-Reply-To: <87367nfd5d.fsf-ueno@gnu.org> References: <7d7cfa6e-af75-82d0-e076-bf411b87a3ab@gmx.de> <3209909.82nJG28bfC@omega> <87367nfd5d.fsf-ueno@gnu.org> MIME-Version: 1.0 Content-Transfer-Encoding: 7Bit Content-Type: text/plain; charset="us-ascii" Received-SPF: none client-ip=2a01:238:20a:202:5300::1; envelope-from=bruno@clisp.org; helo=mo6-p00-ob.smtp.rzone.de X-detected-operating-system: by eggs.gnu.org: No matching host in p0f cache. That's all we know. X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_PASS=-0.001, URIBL_BLOCKED=0.001 autolearn=_AUTOLEARN X-Spam_action: no action X-BeenThere: bug-gnulib@gnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: Gnulib discussion list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Tim =?ISO-8859-1?Q?R=FChsen?= , bug-gnulib@gnu.org Errors-To: bug-gnulib-bounces+normalperson=yhbt.net@gnu.org Sender: "bug-gnulib" Hi Daiki, > Thank you for this; would it make sense to use it in the modules that do > one-shot fopen/fclose, such as read-file? This would improve things for multithreaded programs that call exec or posix_spawn. There are not that many programs of this kind. But on the other hand, multithreading is meant to be a "built-in" functionality nowadays, and the burden of fopen-gnu is zero on the majority of the modern platforms and small on the other platforms. => I've applied your patch. Bruno