Re: [PATCH] sound: rt5645: fix a NULL pointer dereference

2019-03-23 Thread Aditya Pakki
On 3/14/19 10:48 PM, Kangjie Lu wrote: > devm_kcalloc() may fail and return NULL. The fix returns ENOMEM > in case it fails to avoid NULL pointer dereference. > > Signed-off-by: Kangjie Lu > --- > sound/soc/codecs/rt5645.c | 3 +++ > 1 file changed, 3 insertions(+) > > diff --git

[PATCH] sound: rt5645: fix a NULL pointer dereference

2019-03-14 Thread Kangjie Lu
devm_kcalloc() may fail and return NULL. The fix returns ENOMEM in case it fails to avoid NULL pointer dereference. Signed-off-by: Kangjie Lu --- sound/soc/codecs/rt5645.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/sound/soc/codecs/rt5645.c b/sound/soc/codecs/rt5645.c index