All of lore.kernel.org
 help / color / mirror / Atom feed
* + ocfs2-fix-memory-leak-in-ocfs2_merge_rec_left.patch added to mm-nonmm-unstable branch
@ 2025-12-06 21:46 Andrew Morton
  0 siblings, 0 replies; only message in thread
From: Andrew Morton @ 2025-12-06 21:46 UTC (permalink / raw)
  To: mm-commits, piaojun, mark, junxiao.bi, joseph.qi, jlbec,
	heming.zhao, gechangwei, dmantipov, akpm


The patch titled
     Subject: ocfs2: fix memory leak in ocfs2_merge_rec_left()
has been added to the -mm mm-nonmm-unstable branch.  Its filename is
     ocfs2-fix-memory-leak-in-ocfs2_merge_rec_left.patch

This patch will shortly appear at
     https://git.kernel.org/pub/scm/linux/kernel/git/akpm/25-new.git/tree/patches/ocfs2-fix-memory-leak-in-ocfs2_merge_rec_left.patch

This patch will later appear in the mm-nonmm-unstable branch at
    git://git.kernel.org/pub/scm/linux/kernel/git/akpm/mm

Before you just go and hit "reply", please:
   a) Consider who else should be cc'ed
   b) Prefer to cc a suitable mailing list as well
   c) Ideally: find the original patch on the mailing list and do a
      reply-to-all to that, adding suitable additional cc's

*** Remember to use Documentation/process/submit-checklist.rst when testing your code ***

The -mm tree is included into linux-next via the mm-everything
branch at git://git.kernel.org/pub/scm/linux/kernel/git/akpm/mm
and is updated there every 2-3 working days

------------------------------------------------------
From: Dmitry Antipov <dmantipov@yandex.ru>
Subject: ocfs2: fix memory leak in ocfs2_merge_rec_left()
Date: Fri, 5 Dec 2025 09:51:59 +0300

In 'ocfs2_merge_rec_left()', do not reset 'left_path' to NULL after
move, thus allowing 'ocfs2_free_path()' to free it before return.

Link: https://lkml.kernel.org/r/20251205065159.392749-1-dmantipov@yandex.ru
Fixes: 677b975282e4 ("ocfs2: Add support for cross extent block")
Signed-off-by: Dmitry Antipov <dmantipov@yandex.ru>
Reported-by: syzbot+cfc7cab3bb6eaa7c4de2@syzkaller.appspotmail.com
Closes: https://syzkaller.appspot.com/bug?extid=cfc7cab3bb6eaa7c4de2
Reviewed-by: Heming Zhao <heming.zhao@suse.com>
Acked-by: Joseph Qi <joseph.qi@linux.alibaba.com>
Cc: Mark Fasheh <mark@fasheh.com>
Cc: Joel Becker <jlbec@evilplan.org>
Cc: Junxiao Bi <junxiao.bi@oracle.com>
Cc: Changwei Ge <gechangwei@live.cn>
Cc: Jun Piao <piaojun@huawei.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
---

 fs/ocfs2/alloc.c |    1 -
 1 file changed, 1 deletion(-)

--- a/fs/ocfs2/alloc.c~ocfs2-fix-memory-leak-in-ocfs2_merge_rec_left
+++ a/fs/ocfs2/alloc.c
@@ -3655,7 +3655,6 @@ static int ocfs2_merge_rec_left(struct o
 			 * So we use the new rightmost path.
 			 */
 			ocfs2_mv_path(right_path, left_path);
-			left_path = NULL;
 		} else
 			ocfs2_complete_edge_insert(handle, left_path,
 						   right_path, subtree_index);
_

Patches currently in -mm which might be from dmantipov@yandex.ru are

ocfs2-fix-memory-leak-in-ocfs2_merge_rec_left.patch


^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2025-12-06 21:46 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-12-06 21:46 + ocfs2-fix-memory-leak-in-ocfs2_merge_rec_left.patch added to mm-nonmm-unstable branch Andrew Morton

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.