diff options
author | Dinghao Liu <dinghao.liu@zju.edu.cn> | 2020-08-21 08:49:16 +0300 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab+huawei@kernel.org> | 2020-09-03 12:01:56 +0300 |
commit | c1bca5b5ced0cbd779d56f60cdbc9f5e6f6449fe (patch) | |
tree | 8cb2a0c7cdc45e3909902e5d683a71d4d2a3b5b1 /drivers/staging/media/atomisp/pci | |
parent | 5b4b09788dc156d88f54ba0b5fe26d84c03728d4 (diff) | |
download | linux-c1bca5b5ced0cbd779d56f60cdbc9f5e6f6449fe.tar.xz |
media: atomisp: fix memleak in ia_css_stream_create
When aspect_ratio_crop_init() fails, curr_stream needs
to be freed just like what we've done in the following
error paths. However, current code is returning directly
and ends up leaking memory.
Signed-off-by: Dinghao Liu <dinghao.liu@zju.edu.cn>
Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
Diffstat (limited to 'drivers/staging/media/atomisp/pci')
-rw-r--r-- | drivers/staging/media/atomisp/pci/sh_css.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/staging/media/atomisp/pci/sh_css.c b/drivers/staging/media/atomisp/pci/sh_css.c index 54434c2dbaf9..8473e1437074 100644 --- a/drivers/staging/media/atomisp/pci/sh_css.c +++ b/drivers/staging/media/atomisp/pci/sh_css.c @@ -9521,7 +9521,7 @@ ia_css_stream_create(const struct ia_css_stream_config *stream_config, if (err) { IA_CSS_LEAVE_ERR(err); - return err; + goto ERR; } #endif for (i = 0; i < num_pipes; i++) |