aboutsummaryrefslogtreecommitdiffstats
path: root/fs/jbd2/commit.c
diff options
context:
space:
mode:
authorWentao_Liang <[email protected]>2022-07-28 11:39:19 +0000
committerJens Axboe <[email protected]>2022-08-03 03:08:53 +0000
commit104212471b1c1817b311771d817fb692af983173 (patch)
treeaa5da3b1c20aaf39f7f759ce4d667889a3385721 /fs/jbd2/commit.c
parentmd/raid5: Ensure batch_last is released before sleeping for quiesce (diff)
downloadkernel-104212471b1c1817b311771d817fb692af983173.tar.gz
kernel-104212471b1c1817b311771d817fb692af983173.zip
drivers:md:fix a potential use-after-free bug
In line 2884, "raid5_release_stripe(sh);" drops the reference to sh and may cause sh to be released. However, sh is subsequently used in lines 2886 "if (sh->batch_head && sh != sh->batch_head)". This may result in an use-after-free bug. It can be fixed by moving "raid5_release_stripe(sh);" to the bottom of the function. Signed-off-by: Wentao_Liang <[email protected]> Signed-off-by: Song Liu <[email protected]> Signed-off-by: Jens Axboe <[email protected]>
Diffstat (limited to 'fs/jbd2/commit.c')
0 files changed, 0 insertions, 0 deletions