mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2024-08-27 03:10:12 +00:00
media: vpbe_venc: potential uninitialized variable in ven_sub_dev_init()
Smatch complains that "venc" could be uninitialized. There are a couple of error paths where it looks like maybe that could happen. I don't know if it's really a bug, but it's reasonable to set "venc" to NULL and silence the warning. Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab+samsung@kernel.org>
This commit is contained in:
parent
f6b6631478
commit
6246c3a43b
1 changed files with 1 additions and 1 deletions
|
@ -606,7 +606,7 @@ static int venc_device_get(struct device *dev, void *data)
|
|||
struct v4l2_subdev *venc_sub_dev_init(struct v4l2_device *v4l2_dev,
|
||||
const char *venc_name)
|
||||
{
|
||||
struct venc_state *venc;
|
||||
struct venc_state *venc = NULL;
|
||||
|
||||
bus_for_each_dev(&platform_bus_type, NULL, &venc,
|
||||
venc_device_get);
|
||||
|
|
Loading…
Reference in a new issue