diff options
author | Philipp Zabel <p.zabel@pengutronix.de> | 2015-01-23 19:51:22 +0300 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab@osg.samsung.com> | 2015-02-02 15:02:13 +0300 |
commit | 1c2f6a9983a7b079c4bada2bb43c336bb7b8abb9 (patch) | |
tree | 9d483e026ce26ee5024c0ca11fbe36859b6dbbc7 /drivers/media/platform/coda | |
parent | 5f9826e8a759426f6fd722a80a72008bd93132af (diff) | |
download | linux-1c2f6a9983a7b079c4bada2bb43c336bb7b8abb9.tar.xz |
[media] coda: properly clear f_cap in coda_s_fmt_vid_out
Properly zero the structure on the stack before using it.
Signed-off-by: Philipp Zabel <p.zabel@pengutronix.de>
Signed-off-by: Kamil Debski <k.debski@samsung.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
Diffstat (limited to 'drivers/media/platform/coda')
-rw-r--r-- | drivers/media/platform/coda/coda-common.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/media/platform/coda/coda-common.c b/drivers/media/platform/coda/coda-common.c index ff7da3a5c4ae..d26794fa74bf 100644 --- a/drivers/media/platform/coda/coda-common.c +++ b/drivers/media/platform/coda/coda-common.c @@ -674,6 +674,7 @@ static int coda_s_fmt_vid_out(struct file *file, void *priv, ctx->colorspace = f->fmt.pix.colorspace; + memset(&f_cap, 0, sizeof(f_cap)); f_cap.type = V4L2_BUF_TYPE_VIDEO_CAPTURE; coda_g_fmt(file, priv, &f_cap); f_cap.fmt.pix.width = f->fmt.pix.width; |