From owner-svn-src-all@freebsd.org Sun Apr 9 16:01:00 2017 Return-Path: Delivered-To: svn-src-all@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 E2AB8D3680A; Sun, 9 Apr 2017 16:01:00 +0000 (UTC) (envelope-from danfe@freebsd.org) Received: from freefall.freebsd.org (freefall.freebsd.org [96.47.72.132]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "freefall.freebsd.org", Issuer "Let's Encrypt Authority X3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id C463B9D0; Sun, 9 Apr 2017 16:01:00 +0000 (UTC) (envelope-from danfe@freebsd.org) Received: by freefall.freebsd.org (Postfix, from userid 1033) id E09E57F65; Sun, 9 Apr 2017 16:00:59 +0000 (UTC) Date: Sun, 9 Apr 2017 16:00:59 +0000 From: Alexey Dokuchaev To: Cy Schubert Cc: Konstantin Belousov , src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: Re: svn commit: r313495 - head/sys/kern Message-ID: <20170409160059.GA75974@FreeBSD.org> References: <201702092335.v19NZvSQ026869@repo.freebsd.org> <201702100521.v1A5LgfJ003611@slippy.cwsent.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <201702100521.v1A5LgfJ003611@slippy.cwsent.com> User-Agent: Mutt/1.7.1 (2016-10-04) X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 09 Apr 2017 16:01:01 -0000 On Thu, Feb 09, 2017 at 09:21:42PM -0800, Cy Schubert wrote: > In message <201702092335.v19NZvSQ026869@repo.freebsd.org>, Konstantin > Belousov writes: > > New Revision: 313495 > > URL: https://svnweb.freebsd.org/changeset/base/313495 > > > > Log: > > ... > > Restructure the block in vn_open_vnode() which handles O_EXLOCK and > > O_SHLOCK open flags to make it easier to quit its execution earlier > > with an error. > > This broke dhclient. I've attached typescript output at the end of this > email. > > > @@ -376,20 +384,20 @@ vn_open_vnode(struct vnode *vp, int fmod > > * Ensure the vnode is still able to be opened for > > * writing after the lock has been obtained. > > */ > > - if (error == 0 && accmode & VWRITE) > > + if ((accmode & VWRITE) != 0) > > error = vn_writechk(vp); > > + break; > > + } Could it be related to this hunk? It unconditionally breaks out of the loop now (missing { } in that `if')? PVS-Studio trips at here: /usr/src/sys/kern/vfs_vnops.c:389:1: warning: V612 An unconditional 'break' within a loop. ./danfe