All of lore.kernel.org
 help / color / mirror / Atom feed
* [merged mm-hotfixes-stable] mm-huge_memory-handle-strsep-not-finding-delimiter.patch removed from -mm tree
@ 2024-12-19  3:05 Andrew Morton
  0 siblings, 0 replies; only message in thread
From: Andrew Morton @ 2024-12-19  3:05 UTC (permalink / raw)
  To: mm-commits, leocstone, akpm


The quilt patch titled
     Subject: mm: huge_memory: handle strsep not finding delimiter
has been removed from the -mm tree.  Its filename was
     mm-huge_memory-handle-strsep-not-finding-delimiter.patch

This patch was dropped because it was merged into the mm-hotfixes-stable branch
of git://git.kernel.org/pub/scm/linux/kernel/git/akpm/mm

------------------------------------------------------
From: Leo Stone <leocstone@gmail.com>
Subject: mm: huge_memory: handle strsep not finding delimiter
Date: Sun, 15 Dec 2024 20:27:51 -0800

split_huge_pages_write() does not handle the case where strsep finds no
delimiter in the given string and sets the input buffer to NULL, which
allows this reproducer to trigger a protection fault.

Link: https://lkml.kernel.org/r/20241216042752.257090-2-leocstone@gmail.com
Signed-off-by: Leo Stone <leocstone@gmail.com>
Reported-by: syzbot+8a3da2f1bbf59227c289@syzkaller.appspotmail.com
Closes: https://syzkaller.appspot.com/bug?extid=8a3da2f1bbf59227c289
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
---

 mm/huge_memory.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

--- a/mm/huge_memory.c~mm-huge_memory-handle-strsep-not-finding-delimiter
+++ a/mm/huge_memory.c
@@ -4169,7 +4169,7 @@ static ssize_t split_huge_pages_write(st
 		size_t input_len = strlen(input_buf);
 
 		tok = strsep(&buf, ",");
-		if (tok) {
+		if (tok && buf) {
 			strscpy(file_path, tok);
 		} else {
 			ret = -EINVAL;
_

Patches currently in -mm which might be from leocstone@gmail.com are



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

only message in thread, other threads:[~2024-12-19  3:05 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-12-19  3:05 [merged mm-hotfixes-stable] mm-huge_memory-handle-strsep-not-finding-delimiter.patch removed from -mm tree 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.