There is stringop-overflow warning to use strncat and bound check
for buffer size for the string is already done. Fix string
concatenate with strncat() by replacing with strcat().
Change-Id: I94a75bab9a4e62da4b8796cf3ae223ce8f1f715a
Signed-off-by: Seung-Woo Kim <sw0312.kim@samsung.com>
len = strlen(if_name);
ch = if_name[len - 1];
if ((ch > '9' || ch < '0') && (len < IFNAMSIZ - 2))
- strncat(if_name, "%d", 2);
+ strcat(if_name, "%d");
}
/* Passing NULL to dngl_name to ensure host gets if_name in dngl_name member */