Commit 57e7239c authored by Charles Han's avatar Charles Han Committed by Theodore Ts'o
Browse files

ext4: fix potential null dereference in ext4 kunit test



kunit_kzalloc() may return a NULL pointer, dereferencing it
without NULL check may lead to NULL dereference.
Add a NULL check for grp.

Fixes: ac96b56a ("ext4: Add unit test for mb_mark_used")
Fixes: b7098e1f ("ext4: Add unit test for mb_free_blocks")
Signed-off-by: default avatarCharles Han <hanchunchao@inspur.com>
Reviewed-by: default avatarKemeng Shi <shikemeng@huaweicloud.com>
Link: https://patch.msgid.link/20250110092421.35619-1-hanchunchao@inspur.com


Signed-off-by: default avatarTheodore Ts'o <tytso@mit.edu>
parent 30cbe84d
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment