From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from relay.sgi.com (relay2.corp.sgi.com [137.38.102.29]) by oss.sgi.com (Postfix) with ESMTP id A6E3E7F87 for ; Wed, 1 Oct 2014 10:55:30 -0500 (CDT) Received: from cuda.sgi.com (cuda3.sgi.com [192.48.176.15]) by relay2.corp.sgi.com (Postfix) with ESMTP id 85D0930406A for ; Wed, 1 Oct 2014 08:55:30 -0700 (PDT) Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.9]) by cuda.sgi.com with ESMTP id BZ5TAEgim7w193Z3 (version=TLSv1 cipher=AES256-SHA bits=256 verify=NO) for ; Wed, 01 Oct 2014 08:55:29 -0700 (PDT) Date: Wed, 1 Oct 2014 08:55:29 -0700 From: Christoph Hellwig Subject: Re: [PATCH 1/2] xfs: don't send null bp to xfs_trans_brelse() Message-ID: <20141001155529.GA787@infradead.org> References: <542C1B36.5080804@redhat.com> <542C1C2B.5020803@sandeen.net> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: <542C1C2B.5020803@sandeen.net> List-Id: XFS Filesystem from SGI List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Errors-To: xfs-bounces@oss.sgi.com Sender: xfs-bounces@oss.sgi.com To: Eric Sandeen Cc: xfs-oss On Wed, Oct 01, 2014 at 10:22:19AM -0500, Eric Sandeen wrote: > In this case, if bp is NULL, error is set, and we send a > NULL bp to xfs_trans_brelse, which will try to dereference it. > > Test whether we actually have a buffer before we try to > free it. > > Coverity spotted this. > > Signed-off-by: Eric Sandeen Looks good, Reviewed-by: Christoph Hellwig _______________________________________________ xfs mailing list xfs@oss.sgi.com http://oss.sgi.com/mailman/listinfo/xfs