Re: [PATCH] media: fdp1: Fix a memory leak bug

2019-08-21 Thread Kieran Bingham
Hi Wenwen, On 18/08/2019 06:58, Wenwen Wang wrote: > In fdp1_open(), 'ctx' is allocated through kzalloc(). However, it is not > deallocated if v4l2_ctrl_new_std() fails, leading to a memory leak bug. To > fix this issue, free 'ctx' before going to the 'done' label. We could also free it up in the

[PATCH] media: fdp1: Fix a memory leak bug

2019-08-17 Thread Wenwen Wang
In fdp1_open(), 'ctx' is allocated through kzalloc(). However, it is not deallocated if v4l2_ctrl_new_std() fails, leading to a memory leak bug. To fix this issue, free 'ctx' before going to the 'done' label. Signed-off-by: Wenwen Wang --- drivers/media/platform/rcar_fdp1.c | 1 + 1 file