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

Commit c817d927 authored by Hans Verkuil's avatar Hans Verkuil Committed by Mauro Carvalho Chehab
Browse files

[media] v4l2-ctrls: replace BUG_ON by WARN_ON



BUG_ON is unnecessarily strict.

Signed-off-by: default avatarHans Verkuil <hans.verkuil@cisco.com>
Signed-off-by: default avatarMauro Carvalho Chehab <m.chehab@samsung.com>
parent 9b058373
Loading
Loading
Loading
Loading
+2 −1
Original line number Diff line number Diff line
@@ -1942,7 +1942,8 @@ void v4l2_ctrl_cluster(unsigned ncontrols, struct v4l2_ctrl **controls)
	int i;

	/* The first control is the master control and it must not be NULL */
	BUG_ON(ncontrols == 0 || controls[0] == NULL);
	if (WARN_ON(ncontrols == 0 || controls[0] == NULL))
		return;

	for (i = 0; i < ncontrols; i++) {
		if (controls[i]) {