提交 b6ae906b 编写于 作者: P Pawel Osciak 提交者: Mauro Carvalho Chehab

V4L/DVB: v4l: mem2mem_testdev: fix g_fmt NULL pointer dereference

Calling g_fmt before s_fmt resulted in a NULL pointer dereference as no
default formats were being selected on probe.
Reported-by: NNémeth Márton <nm127@freemail.hu>
Signed-off-by: NPawel Osciak <p.osciak@samsung.com>
Signed-off-by: NKyungmin Park <kyungmin.park@samsung.com>
Signed-off-by: NMauro Carvalho Chehab <mchehab@redhat.com>
上级 9c3b10b5
......@@ -988,6 +988,9 @@ static int m2mtest_probe(struct platform_device *pdev)
goto err_m2m;
}
q_data[V4L2_M2M_SRC].fmt = &formats[0];
q_data[V4L2_M2M_DST].fmt = &formats[0];
return 0;
err_m2m:
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册