From 3464dff5c9fc1ced18d9bfd32f754ab61c85f671 Mon Sep 17 00:00:00 2001 From: "Darrick J. Wong" Date: Thu, 28 Jun 2018 15:11:57 -0500 Subject: [PATCH] xfs: fix inobt magic number check Source kernel commit: 2e050e648ad6c74a2f0a28f645155128be0626ca In commit a6a781a58befcbd467c ("xfs: have buffer verifier functions report failing address") the bad magic number return was ported incorrectly. Fixes: a6a781a58befcbd467ce843af4eaca3906aa1f08 Reported-by: syzbot+08ab33be0178b76851c8@syzkaller.appspotmail.com Signed-off-by: Darrick J. Wong Reviewed-by: Eric Sandeen Signed-off-by: Eric Sandeen --- libxfs/xfs_ialloc_btree.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libxfs/xfs_ialloc_btree.c b/libxfs/xfs_ialloc_btree.c index 3efa769c3..287789321 100644 --- a/libxfs/xfs_ialloc_btree.c +++ b/libxfs/xfs_ialloc_btree.c @@ -295,7 +295,7 @@ xfs_inobt_verify( case cpu_to_be32(XFS_FIBT_MAGIC): break; default: - return NULL; + return __this_address; } /* level verification */ -- 2.47.2