提交 b36b5059 编写于 作者: H Hans de Goede 提交者: Mauro Carvalho Chehab

[media] v4l2-event: Deny subscribing with a type of V4L2_EVENT_ALL

Signed-off-by: NHans de Goede <hdegoede@redhat.com>
Acked-by: NLaurent Pinchart <laurent.pinchart@ideasonboard.com>
Acked-by: NHans Verkuil <hans.verkuil@cisco.com>
Signed-off-by: NMauro Carvalho Chehab <mchehab@redhat.com>
上级 60659dd4
......@@ -215,6 +215,9 @@ int v4l2_event_subscribe(struct v4l2_fh *fh,
unsigned long flags;
unsigned i;
if (sub->type == V4L2_EVENT_ALL)
return -EINVAL;
if (elems < 1)
elems = 1;
if (sub->type == V4L2_EVENT_CTRL) {
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册