nilfs2: Remove check for PageError
[ Upstream commit 79ea65563a
]
If read_mapping_page() encounters an error, it returns an errno, not a
page with PageError set, so this test is not needed.
This is for CVE-2024-39469.
Signed-off-by: Matthew Wilcox (Oracle) <willy@infradead.org>
Stable-dep-of: 7373a51e7998 ("nilfs2: fix nilfs_empty_dir() misjudgment and long loop on I/O errors")
Signed-off-by: Sasha Levin <sashal@kernel.org>
Signed-off-by: katrinzhou <katrinzhou@tencent.com>
Signed-off-by: Jianping Liu <frankjpliu@tencent.com>
This commit is contained in:
parent
dbfad4e00a
commit
6101cce36b
|
@ -194,7 +194,7 @@ static struct page *nilfs_get_page(struct inode *dir, unsigned long n)
|
|||
if (!IS_ERR(page)) {
|
||||
kmap(page);
|
||||
if (unlikely(!PageChecked(page))) {
|
||||
if (PageError(page) || !nilfs_check_page(page))
|
||||
if (!nilfs_check_page(page))
|
||||
goto fail;
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue