cec-api: prevent leaking memory through hole in structure
authorHans Verkuil <hverkuil-cisco@xs4all.nl>
Fri, 26 Jun 2020 10:44:26 +0000 (12:44 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 3 Sep 2020 09:29:20 +0000 (11:29 +0200)
commit72db989557d993793c01ba84eb98f3cbf2a7f4cf
treefef9c0dd7f96dbc4562d286fa740952fa1dc4141
parent41399a7d4f5031abd6a436b836ba3b56765101b7
cec-api: prevent leaking memory through hole in structure

[ Upstream commit 6c42227c3467549ddc65efe99c869021d2f4a570 ]

Fix this smatch warning:

drivers/media/cec/core/cec-api.c:156 cec_adap_g_log_addrs() warn: check that 'log_addrs' doesn't leak information (struct has a hole after
'features')

Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/media/cec/core/cec-api.c