aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSergei A. Trusov <sergei.a.trusov@ya.ru>2017-08-02 04:00:01 -0400
committerMauro Carvalho Chehab <mchehab@s-opensource.com>2017-08-09 10:49:36 -0400
commit0659445f47586b128613e011eae9f24b07ebe838 (patch)
tree0aeed1fa4480a2402cbdeba9be37d515fa80932b
parent46a41ebd23662336ac13df8189a2655cd2537554 (diff)
media: staging: atomisp: sh_css_calloc shall return a pointer to the allocated space
The calloc function returns either a null pointer or a pointer to the allocated space. Add the second case that is missed. Fixes: da22013f7df4 ("atomisp: remove indirection from sh_css_malloc") Signed-off-by: Sergei A. Trusov <sergei.a.trusov@ya.ru> Signed-off-by: Sakari Ailus <sakari.ailus@linux.intel.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
-rw-r--r--drivers/staging/media/atomisp/pci/atomisp2/css2400/sh_css.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/staging/media/atomisp/pci/atomisp2/css2400/sh_css.c b/drivers/staging/media/atomisp/pci/atomisp2/css2400/sh_css.c
index 471f2be974e2..e882b5596813 100644
--- a/drivers/staging/media/atomisp/pci/atomisp2/css2400/sh_css.c
+++ b/drivers/staging/media/atomisp/pci/atomisp2/css2400/sh_css.c
@@ -1939,6 +1939,7 @@ void *sh_css_calloc(size_t N, size_t size)
p = sh_css_malloc(N*size);
if (p)
memset(p, 0, size);
+ return p;
}
return NULL;
}

Privacy Policy