From nobody Fri Dec 19 15:48:40 2025 Received: from mail-oi1-f197.google.com (mail-oi1-f197.google.com [209.85.167.197]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 38F342D780C for ; Fri, 5 Dec 2025 07:51:09 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.167.197 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1764921084; cv=none; b=uVM39W7ighUesFZJSpUDCApmFNxjdFwBDHYQYAcreRlvw0mta705NiffzVAYYaYj643X/hLn0ggJPAOFv3zV7IXsHHf7wzSynLFQwwZmvBVsTAhuJjxdPNFfYb2N9hMbfAtNBKPHe/iRIHyOiR9z6nN/yb8VXD8aB0xG/Efq3B0= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1764921084; c=relaxed/simple; bh=j/HRba4GutObWTJNDUbR76QzGVT3J7RUknVk1vY0IOA=; h=MIME-Version:Date:In-Reply-To:Message-ID:Subject:From:To: Content-Type; b=W/RsYdo3zm+fdoJ2ttciSF5+5EF/b3k23WdgNvpFmggEBj7twLVPxp5A/NtZys77FulXkt7xe/y2Li76ah03YzZfl3eS4e2t0ajhEzuw9ByibOep2C8lTYdYrKwz97BQWuXn38gxqhSBzEfzsPfYvInXH+vdb3M53oi2pBKncLU= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=fail (p=none dis=none) header.from=syzkaller.appspotmail.com; spf=pass smtp.mailfrom=M3KW2WVRGUFZ5GODRSRYTGD7.apphosting.bounces.google.com; arc=none smtp.client-ip=209.85.167.197 Authentication-Results: smtp.subspace.kernel.org; dmarc=fail (p=none dis=none) header.from=syzkaller.appspotmail.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=M3KW2WVRGUFZ5GODRSRYTGD7.apphosting.bounces.google.com Received: by mail-oi1-f197.google.com with SMTP id 5614622812f47-45033344baeso4155204b6e.1 for ; Thu, 04 Dec 2025 23:51:06 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1764921062; x=1765525862; h=to:from:subject:message-id:in-reply-to:date:mime-version :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=ooXmwuhOS+0hhCcIcs9O6yc0XyK+YGqrK6pWmRAQRmo=; b=WivA3czcgIgPDDq/cGZGLffX5qTKbCNZCgujpTiZh7LK4DvaL7vmyxyVRyGs5nQaud cxRa8P1Oq0+yTNq6dAmxmtnJeaownhR60rz3FE34zKBul2Dxd1IqzYvEXk/kJeAI59uZ Hm5TMejKt1IqhvSC/OhkCWt4Vyb4Knbkkcb/sdx+PYfhJLAVJ/ykOgf2dF62drDgqEuR s8uh9V8FGUjebYfHwNLV9/RF7TKNj6x5H7x4HzS/oHzgvedE6pxoGjW3CYNmk3i8QsH+ 8xttokXA8VOBALB8ezv78BC3+IxNEozjn/QBE2SbTlrQZMDRThtzo9L6w1PUkojegDWQ xVgQ== X-Gm-Message-State: AOJu0Yy1EDg7eMha+7EcWwy59huJr9redBwiLUXi2ykg+m2ZKmdEBCTM o7GzsqZeaopOVZ7l59bulJRdVLUEvq0ykqRf1oNeUTwYpDc+Rh4ZWAv6BXSKwCz3rtwUBcC+Cz+ afJTjUk+9Cv/H9vC0LRs6kLlch9MKB6eMlge9Iu46Q+jArZvYvR+K+6h4fEg= X-Google-Smtp-Source: AGHT+IHjkoPA+RoafBv/SBGkARaNTBmMqEtN1S0+sMO3SZIegxJFPKFyGA6z0vO3RbllOrOjoyMTjUAS4oGY/SwDKOnORL0iGbrg Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-Received: by 2002:a05:6808:1807:b0:450:ccc6:4124 with SMTP id 5614622812f47-4536e4f4cefmr4012993b6e.37.1764921062663; Thu, 04 Dec 2025 23:51:02 -0800 (PST) Date: Thu, 04 Dec 2025 23:51:02 -0800 In-Reply-To: <69326fcf.a70a0220.d98e3.01e5.GAE@google.com> X-Google-Appengine-App-Id: s~syzkaller X-Google-Appengine-App-Id-Alias: syzkaller Message-ID: <69328ee6.050a0220.3a66f.0001.GAE@google.com> Subject: Forwarded: [PATCH] hfsplus: fix memory leak in hfsplus_fill_super() error path From: syzbot To: linux-kernel@vger.kernel.org, syzkaller-bugs@googlegroups.com Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" For archival purposes, forwarding an incoming command email to linux-kernel@vger.kernel.org, syzkaller-bugs@googlegroups.com. *** Subject: [PATCH] hfsplus: fix memory leak in hfsplus_fill_super() error path Author: kartikey406@gmail.com #syz test: git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git= master When hfsplus_fill_super() fails, the sbi structure is freed but sb->s_fs_info is not set to NULL, leaving a dangling pointer. This can lead to memory leak as reported by syzbot. Set sb->s_fs_info to NULL after freeing sbi in the error path to ensure proper cleanup. Reported-by: syzbot+99f6ed51479b86ac4c41@syzkaller.appspotmail.com Closes: https://syzkaller.appspot.com/bug?extid=3D99f6ed51479b86ac4c41 Signed-off-by: Deepanshu Kartikey --- fs/hfsplus/super.c | 1 + 1 file changed, 1 insertion(+) diff --git a/fs/hfsplus/super.c b/fs/hfsplus/super.c index 54e85e25a259..eb1b262be45e 100644 --- a/fs/hfsplus/super.c +++ b/fs/hfsplus/super.c @@ -630,6 +630,7 @@ static int hfsplus_fill_super(struct super_block *sb, s= truct fs_context *fc) unload_nls(sbi->nls); unload_nls(nls); kfree(sbi); + sb->s_fs_info =3D NULL; return err; } =20 --=20 2.43.0