From a285cd7d77faec628f4a6ffcc782841a310b438e Mon Sep 17 00:00:00 2001 From: "Guoniu.Zhou" Date: Thu, 20 Dec 2018 10:28:42 +0800 Subject: [PATCH] MLK-20192-2: ISI: Coverity: remove the dead code Because the address of an object is never null and the if statement will never true so remove the dead code Signed-off-by: Guoniu.Zhou --- drivers/media/platform/imx8/mxc-isi-cap.c | 3 --- 1 file changed, 3 deletions(-) diff --git a/drivers/media/platform/imx8/mxc-isi-cap.c b/drivers/media/platform/imx8/mxc-isi-cap.c index 45d0b7e3ffb2..bca2ea612c49 100644 --- a/drivers/media/platform/imx8/mxc-isi-cap.c +++ b/drivers/media/platform/imx8/mxc-isi-cap.c @@ -786,9 +786,6 @@ static int mxc_isi_cap_enum_fmt_mplane(struct file *file, void *priv, return -EINVAL; fmt = &mxc_isi_out_formats[f->index]; - if (!fmt) - return -EINVAL; - strncpy(f->description, fmt->name, sizeof(f->description) - 1); f->pixelformat = fmt->fourcc; -- 2.17.1