diff options
author | Daniel Niv <danielniv3@gmail.com> | 2021-03-11 03:53:00 +0100 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab+huawei@kernel.org> | 2021-03-22 11:53:03 +0100 |
commit | c759b2970c561e3b56aa030deb13db104262adfe (patch) | |
tree | 5299aabf6eb1a905eeb3faa3c165675cd4698636 /security | |
parent | aa966274d62957c67126c28433e5a5e188516d3c (diff) |
media: media/saa7164: fix saa7164_encoder_register() memory leak bugs
Add a fix for the memory leak bugs that can occur when the
saa7164_encoder_register() function fails.
The function allocates memory without explicitly freeing
it when errors occur.
Add a better error handling that deallocate the unused buffers before the
function exits during a fail.
Signed-off-by: Daniel Niv <danielniv3@gmail.com>
Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
Diffstat (limited to 'security')
0 files changed, 0 insertions, 0 deletions