From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-lj1-f196.google.com (mail-lj1-f196.google.com [209.85.208.196]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by dev.tarantool.org (Postfix) with ESMTPS id 6B19345C316 for ; Tue, 14 Apr 2020 15:03:59 +0300 (MSK) Received: by mail-lj1-f196.google.com with SMTP id l14so5177297ljj.5 for ; Tue, 14 Apr 2020 05:03:59 -0700 (PDT) Date: Tue, 14 Apr 2020 15:03:56 +0300 From: Cyrill Gorcunov Message-ID: <20200414120356.GE3072@uranus> References: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: Subject: Re: [Tarantool-patches] [PATCH 08/12] popen: fix close-on-exec flag setting List-Id: Tarantool development patches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Alexander Turenko Cc: tarantool-patches@dev.tarantool.org On Tue, Apr 14, 2020 at 02:38:17PM +0300, Alexander Turenko wrote: > fcntl(2) lists flags that can be set using F_SETFL: O_CLOEXEC is not > included there. F_SETFD should be used to set close-on-exec. > > Parent's end of pipes are closed explicitly in a child process anyway. > However this change fixes closing of the copy of a logger fd. See commit > 07a07b3cc7b85375d20b3fc6ca1e5060304f337b ('popen: decouple logger fd > from stderr') for more information why this file descriptor was > introduced. > > Part of #4031. Good catch! Acked-by: Cyrill Gorcunov