lkml.org 
[lkml]   [2015]   [Nov]   [30]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH] ASoC: rsnd: fix a possible NULL dereference
On Thu, Nov 26, 2015 at 08:17:15AM +0100, LABBE Corentin wrote:
> On Wed, Nov 25, 2015 at 11:46:45PM +0000, Kuninori Morimoto wrote:

> > > + of_data = of_device_get_match_data(dev);
> > > + if (!of_data)
> > > + return 1;

> > return 1 ?
> > You want to use -EINVAL ?

> I do that Uwe Kleine-König said to me to do in others thread:
> https://lkml.org/lkml/2015/11/12/70 and https://lkml.org/lkml/2015/11/16/211

What error code to return is going to depend on the context - you need
to look at what the caller is expecting and how it will handle the value
returned.
[unhandled content-type:application/pgp-signature]
\
 
 \ /
  Last update: 2015-11-30 18:01    [W:0.099 / U:0.116 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site