On Fri, Aug 07, 2009 at 02:38:53PM +0200, Aaltonen Matti.J (Nokia-D/Tampere) 
wrote:
> Hi.
> 
> On Mon, 2009-07-27 at 17:12 +0200, Valentin Eduardo (Nokia-D/Helsinki)
> wrote:
> > This patch adds files to control si4713 devices.
> > Internal functions to control device properties
> 
> ....
> 
> > + */
> > +/* si4713_probe - probe for the device */
> > +static int si4713_probe(struct i2c_client *client,
> > +                                       const struct i2c_device_id *id)
> > +{
> > +       struct si4713_device *sdev;
> > +       int rval;
> > +
> > +       sdev = kzalloc(sizeof *sdev, GFP_KERNEL);
> > +       if (!sdev) {
> > +               v4l2_err(&sdev->sd, "Failed to alloc video device.\n");
>                            ^^^^^^^^^^
> > +               rval = -ENOMEM;
> > +               goto exit;
> > +       }
> 
> ....
> 
> You shouldn't do sdev->sd if sdev is NULL.

Ok! Thanks for pointing this Matti!


> 
> Cheers,
> Matti
> 
> 
> 
> 
> 
> 

-- 
Eduardo Valentin
--
To unsubscribe from this list: send the line "unsubscribe linux-media" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to