From patchwork Tue Mar 18 12:02:47 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Wang Shilong X-Patchwork-Id: 3853271 Return-Path: X-Original-To: patchwork-linux-btrfs@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork1.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.19.201]) by patchwork1.web.kernel.org (Postfix) with ESMTP id AA8259F369 for ; Wed, 19 Mar 2014 17:43:22 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id F2A132011B for ; Wed, 19 Mar 2014 17:43:21 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 2C3EE203DC for ; Wed, 19 Mar 2014 17:43:21 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754156AbaCRMF5 (ORCPT ); Tue, 18 Mar 2014 08:05:57 -0400 Received: from cn.fujitsu.com ([222.73.24.84]:16503 "EHLO song.cn.fujitsu.com" rhost-flags-OK-FAIL-OK-OK) by vger.kernel.org with ESMTP id S1751706AbaCRMFG (ORCPT ); Tue, 18 Mar 2014 08:05:06 -0400 X-IronPort-AV: E=Sophos;i="4.97,677,1389715200"; d="scan'208";a="9718676" Received: from unknown (HELO tang.cn.fujitsu.com) ([10.167.250.3]) by song.cn.fujitsu.com with ESMTP; 18 Mar 2014 20:01:06 +0800 Received: from fnstmail02.fnst.cn.fujitsu.com (tang.cn.fujitsu.com [127.0.0.1]) by tang.cn.fujitsu.com (8.14.3/8.13.1) with ESMTP id s2IC4uW8001921 for ; Tue, 18 Mar 2014 20:04:58 +0800 Received: from wangs.fnst.cn.fujitsu.com ([10.167.226.104]) by fnstmail02.fnst.cn.fujitsu.com (Lotus Domino Release 8.5.3) with ESMTP id 2014031820020283-704835 ; Tue, 18 Mar 2014 20:02:02 +0800 From: Wang Shilong To: linux-btrfs@vger.kernel.org Subject: [PATCH 6/6] Btrfs-progs: fsck: fix wrong index in pick_next_pending() Date: Tue, 18 Mar 2014 20:02:47 +0800 Message-Id: <1395144167-775-6-git-send-email-wangsl.fnst@cn.fujitsu.com> X-Mailer: git-send-email 1.9.0 In-Reply-To: <1395144167-775-1-git-send-email-wangsl.fnst@cn.fujitsu.com> References: <1395144167-775-1-git-send-email-wangsl.fnst@cn.fujitsu.com> X-MIMETrack: Itemize by SMTP Server on mailserver/fnst(Release 8.5.3|September 15, 2011) at 2014/03/18 20:02:03, Serialize by Router on mailserver/fnst(Release 8.5.3|September 15, 2011) at 2014/03/18 20:02:04, Serialize complete at 2014/03/18 20:02:04 Sender: linux-btrfs-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-btrfs@vger.kernel.org X-Spam-Status: No, score=-6.9 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_HI, T_RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Though all tree blocks have same size, we'd better use right index here. Signed-off-by: Wang Shilong --- cmds-check.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cmds-check.c b/cmds-check.c index 34f8fa6..ebdb643 100644 --- a/cmds-check.c +++ b/cmds-check.c @@ -2928,7 +2928,7 @@ static int pick_next_pending(struct cache_tree *pending, cache = search_cache_extent(reada, 0); if (cache) { bits[0].start = cache->start; - bits[1].size = cache->size; + bits[0].size = cache->size; *reada_bits = 1; return 1; }