linux/drivers/media/platform/sti
Mauro Carvalho Chehab 54e80d9883 media: sti: don't copy past the size
The logic at delta_ipc_open() tries to copy past the size of
the name passed to it:

	drivers/media/platform/sti/delta/delta-ipc.c:178 delta_ipc_open() error: __memcpy() 'name' too small (17 vs 32)

Basically,this function is called just one with:

	ret = delta_ipc_open(pctx, "JPEG_DECODER_HW0", ...);

The string used there has just 17 bytes. Yet, the logic tries
to copy the entire name size (32 bytes), which is plain wrong.

Replace it by strscpy, which is good enough to copy the string,
warranting that this will be NUL-terminated.

Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
2021-07-12 09:16:31 +02:00
..
bdisp media: bdisp: remove redundant dev_err call in bdisp_probe() 2021-06-02 13:32:05 +02:00
c8sectpfe media: media/platform/sti: fix kernel-doc formatting 2021-03-22 12:54:27 +01:00
delta media: sti: don't copy past the size 2021-07-12 09:16:31 +02:00
hva media: st-hva: Fix potential NULL pointer dereferences 2021-06-02 14:05:00 +02:00