From owner-svn-src-head@freebsd.org Fri Nov 20 23:20:26 2015 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 7F194A334F3 for ; Fri, 20 Nov 2015 23:20:26 +0000 (UTC) (envelope-from mailing-machine@vniz.net) Received: from mail-lb0-f170.google.com (mail-lb0-f170.google.com [209.85.217.170]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 27C3D1A69 for ; Fri, 20 Nov 2015 23:20:25 +0000 (UTC) (envelope-from mailing-machine@vniz.net) Received: by lbblt2 with SMTP id lt2so70439043lbb.3 for ; Fri, 20 Nov 2015 15:20:18 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:subject:to:references:from:message-id:date :user-agent:mime-version:in-reply-to:content-type :content-transfer-encoding; bh=n0p3mVY8VM823BwU+YyXnhmeCbuai0zQwayqqhAC3gs=; b=LpRqzCsM4MmeSeipMKY9xU+4IBwtAau/KWx5NyZzQN9X5r7TFUDwhL5vWh8j2j5KBi 1HJSWxcAh00MqIhp2eLnztNxgfVy+LtikBq/iDdk07gXvq8X3OFuLOVT5oMtYMMeEKCK jZVWP19cVDtFOJso2FQxbuSUqGZsTgLe1yQs8PfIIF+0FlVwZR/kYhJfJ/YvEeYkRRRq RLPSzjmQNr9DAmdNqhiDOFQir9hyiz1l311vFKQCuxMbe2+LKnG2Pq7QzanOkTsVgeSs DuciRNFTg+y/1vf+0XBylzjawxpk9mgOP9koCfA9H+7YMQeYyRyHL5xr/cqLP2z9VY9s 03/w== X-Gm-Message-State: ALoCoQko89OZ5FNvzFvvOfY+pNKr2GX2iAnTknzKxezmQS3P12nlw3FxnKxm9UbdP3K595XQVQ+V X-Received: by 10.112.134.169 with SMTP id pl9mr6746570lbb.145.1448061618269; Fri, 20 Nov 2015 15:20:18 -0800 (PST) Received: from [192.168.1.2] ([89.169.173.68]) by smtp.gmail.com with ESMTPSA id li2sm204859lbc.37.2015.11.20.15.20.17 (version=TLSv1/SSLv3 cipher=OTHER); Fri, 20 Nov 2015 15:20:17 -0800 (PST) Subject: Re: svn commit: r291114 - head/lib/libc/gen To: Ravi Pokala , src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org References: <201511202236.tAKMaf06048447@repo.freebsd.org> From: Andrey Chernov Message-ID: <564FAAB0.6000600@freebsd.org> Date: Sat, 21 Nov 2015 02:20:16 +0300 User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:38.0) Gecko/20100101 Thunderbird/38.3.0 MIME-Version: 1.0 In-Reply-To: <201511202236.tAKMaf06048447@repo.freebsd.org> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 20 Nov 2015 23:20:26 -0000 On 21.11.2015 1:36, Ravi Pokala wrote: > Move fdopen() up near other resource allocation like malloc(); do proper > deallocation on failure later on in the function. Incorrect. Old code calls fdopen() only in the parent, new one calls fdopen() before fork(), so its results shared by both parent and child, which is wrong for child() case. -- http://ache.vniz.net/