lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-ID: <4C513C95.3080403@cn.fujitsu.com>
Date:	Thu, 29 Jul 2010 16:32:21 +0800
From:	Miao Xie <miaox@...fujitsu.com>
To:	Chris Mason <chris.mason@...cle.com>,
	Yan Zheng <zheng.yan@...cle.com>
CC:	Linux Btrfs <linux-btrfs@...r.kernel.org>,
	Linux Kernel <linux-kernel@...r.kernel.org>
Subject: [PATCH 7/7] btrfs: fix a wrong error check in add_ra_bio_pages()

From: Liu Bo <liubo2009@...fujitsu.com>

Only when a page is not found by page_index, we'll go to the error check.

Signed-off-by: Liu Bo <liubo2009@...fujitsu.com>
Signed-off-by: Miao Xie <miaox@...fujitsu.com>
---
 fs/btrfs/compression.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/fs/btrfs/compression.c b/fs/btrfs/compression.c
index cb3877c..8458840 100644
--- a/fs/btrfs/compression.c
+++ b/fs/btrfs/compression.c
@@ -467,7 +467,7 @@ static noinline int add_ra_bio_pages(struct inode *inode,
 		rcu_read_lock();
 		page = radix_tree_lookup(&mapping->page_tree, page_index);
 		rcu_read_unlock();
-		if (page) {
+		if (!page) {
 check_misses:
 			misses++;
 			if (misses > 4)
-- 
1.7.0.1
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ