Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Skip to content
Commit 86b29893 authored by Mauro Carvalho Chehab's avatar Mauro Carvalho Chehab
Browse files

media: uvc: to the right check at uvc_ioctl_enum_framesizes()



While the logic there is correct, it tricks both humans and
machines, a the check if "i" var is not zero is actually to
validate if the "frames" var was initialized when the loop
ran for the first time.

That produces the following warning:
	drivers/media/usb/uvc/uvc_v4l2.c:1192 uvc_ioctl_enum_framesizes() error: potentially dereferencing uninitialized 'frame'.

Change the logic to do the right test instead.

Signed-off-by: default avatarMauro Carvalho Chehab <mchehab@s-opensource.com>
parent 98c1ce0c
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment