From: Takashi Sakamoto <o-takashi@sakamocchi.jp>
To: Charles Han <hanchunchao@inspur.com>
Cc: linux1394-devel@lists.sourceforge.net, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] firewire: test: Fix potential null dereference in firewire kunit test
Date: Mon, 13 Jan 2025 10:42:58 +0900 [thread overview]
Message-ID: <20250113014258.GA68470@workstation.local> (raw)
In-Reply-To: <20250110084237.8877-1-hanchunchao@inspur.com>
Hi,
On Fri, Jan 10, 2025 at 04:42:37PM +0800, Charles Han wrote:
> kunit_kzalloc() may return a NULL pointer, dereferencing it without
> NULL check may lead to NULL dereference.
> Add a NULL check for test_state.
>
> Fixes: 1c8506d62624 ("firewire: test: add test of device attributes for simple AV/C device")
> Signed-off-by: Charles Han <hanchunchao@inspur.com>
> ---
> drivers/firewire/device-attribute-test.c | 2 ++
> 1 file changed, 2 insertions(+)
Applied to for-next branch.
Thanks
Takashi Sakamoto
prev parent reply other threads:[~2025-01-13 1:43 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-01-10 8:42 [PATCH] firewire: test: Fix potential null dereference in firewire kunit test Charles Han
2025-01-13 1:42 ` Takashi Sakamoto [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20250113014258.GA68470@workstation.local \
--to=o-takashi@sakamocchi.jp \
--cc=hanchunchao@inspur.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux1394-devel@lists.sourceforge.net \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox