File fix_strncat_overflow.patch of Package imx-usb-loader

diff --git a/imx_sdp.c b/imx_sdp.c
index 3dec8d5..4f069bd 100644
--- a/imx_sdp.c
+++ b/imx_sdp.c
@@ -144,7 +144,7 @@ char const *conf_path_ok(char const *conf_path, char const *conf_file)
 	static char conf[512];
 
 	strncpy(conf, conf_path, sizeof(conf));
-	strncat(conf, conf_file, sizeof(conf));
+	strncat(conf, conf_file, sizeof(conf) - strlen(conf) - 1);
 	if (access(conf, R_OK) != -1) {
 		printf("config file <%s>\n", conf);
 		return conf;
openSUSE Build Service is sponsored by