devm_kasprintf() returns NULL when memory allocation fails. Currently,
wled_configure() does not check for this case, which results in a NULL
pointer dereference.
Add NULL check after devm_kasprintf() to prevent this issue.
Fixes: f86b77583d88 ("backlight: pm8941: Convert to using %pOFn instead o
Noted, thanks for the feedback! I’ll send subsequent versions as
independent patches in the future.
Best regards,
Henry
Lee Jones 于2025年4月4日周五 23:13写道:
>
> On Fri, 04 Apr 2025, Lee Jones wrote:
>
> > On Tue, 01 Apr 2025 17:16:47 +0800, Henry Martin wrote:
> > > devm_kasprintf() returns NULL whe
On Fri, 04 Apr 2025, Lee Jones wrote:
> On Tue, 01 Apr 2025 17:16:47 +0800, Henry Martin wrote:
> > devm_kasprintf() returns NULL when memory allocation fails. Currently,
> > wled_configure() does not check for this case, which results in a NULL
> > pointer dereference.
> >
> > Add NULL check aft
On Tue, 01 Apr 2025 17:16:47 +0800, Henry Martin wrote:
> devm_kasprintf() returns NULL when memory allocation fails. Currently,
> wled_configure() does not check for this case, which results in a NULL
> pointer dereference.
>
> Add NULL check after devm_kasprintf() to prevent this issue.
>
>
>