media: i2c: gc2093: move from strlcpy with unused retval to strscpy

Signed-off-by: Tao Huang <huangtao@rock-chips.com>
Change-Id: I68e932229e0ed85e57e0f1872b125749def3f7f3
This commit is contained in:
Tao Huang
2025-02-17 19:32:46 +08:00
parent 9ddd8c7588
commit 124b7f171a

View File

@@ -976,9 +976,9 @@ static void gc2093_get_module_inf(struct gc2093 *gc2093,
struct rkmodule_inf *inf)
{
memset(inf, 0, sizeof(*inf));
strlcpy(inf->base.lens, gc2093->len_name, sizeof(inf->base.lens));
strlcpy(inf->base.sensor, GC2093_NAME, sizeof(inf->base.sensor));
strlcpy(inf->base.module, gc2093->module_name, sizeof(inf->base.module));
strscpy(inf->base.lens, gc2093->len_name, sizeof(inf->base.lens));
strscpy(inf->base.sensor, GC2093_NAME, sizeof(inf->base.sensor));
strscpy(inf->base.module, gc2093->module_name, sizeof(inf->base.module));
}
static int gc2093_get_channel_info(struct gc2093 *gc2093,