Avoid the "stringop-overflow" error. The so far specified bound depends on the length of the source argument.
Signed-off-by: Michael Haener <[email protected]> --- env/env_config_partitions.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/env/env_config_partitions.c b/env/env_config_partitions.c index f4b17e2..3b211e6 100644 --- a/env/env_config_partitions.c +++ b/env/env_config_partitions.c @@ -61,7 +61,7 @@ bool probe_config_partitions(CONFIG_PART *cfgpart) return false; } } - strncpy(cfgpart[count].devpath, devpath, + memcpy(cfgpart[count].devpath, devpath, strlen(devpath) + 1); if (probe_config_file(&cfgpart[count])) { printf_debug("%s", "Environment file found.\n"); -- 2.26.3 -- You received this message because you are subscribed to the Google Groups "EFI Boot Guard" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/efibootguard-dev/20210523201800.10148-1-michael.haener%40siemens.com.
