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 AD1A27CA0 for ; Thu, 25 Aug 2016 03:04:55 -0500 (CDT) Received: from cuda.sgi.com (cuda1.sgi.com [192.48.157.11]) by relay2.corp.sgi.com (Postfix) with ESMTP id 5FA9730405F for ; Thu, 25 Aug 2016 01:04:55 -0700 (PDT) Received: from bombadil.infradead.org ([198.137.202.9]) by cuda.sgi.com with ESMTP id 4IIMo24WTLIMtV0i (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128 verify=NO) for ; Thu, 25 Aug 2016 01:04:54 -0700 (PDT) Date: Thu, 25 Aug 2016 01:04:52 -0700 From: Christoph Hellwig Subject: Re: [PATCH] xfs: don't perform lookups on zero-height btrees Message-ID: <20160825080452.GB28747@infradead.org> References: <20160819203022.GD8268@birch.djwong.org> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: <20160819203022.GD8268@birch.djwong.org> 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: "Darrick J. Wong" Cc: linux-xfs@vger.kernel.org, xfs@oss.sgi.com On Fri, Aug 19, 2016 at 01:30:22PM -0700, Darrick J. Wong wrote: > If the caller passes in a cursor to a zero-height btree (which is > impossible), we never set block to anything but NULL, which causes the > later dereference of it to crash. Instead, just return -EFSCORRUPTED. > > Signed-off-by: Darrick J. Wong Looks fine, Reviewed-by: Christoph Hellwig maybe also throw in an unlikely notation, though.. _______________________________________________ xfs mailing list xfs@oss.sgi.com http://oss.sgi.com/mailman/listinfo/xfs