Fix potential memory overflow in welcome string
stage1.c:354:41: warning: '%s' directive output may be truncated writing up to 127 bytes into a region of size 117 [-Wformat-truncation=] snprintf(buf, sizeof(buf), "Welcome to %s", version); ^~ ~~~~~~~ In file included from /usr/include/stdio.h:862, from stage1.c:30: /usr/include/bits/stdio2.h:64:10: note: '__builtin___snprintf_chk' output between 12 and 139 bytes into a destination of size 128 return __builtin___snprintf_chk (__s, __n, __USE_FORTIFY_LEVEL - 1, ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ __bos (__s), __fmt, __va_arg_pack ()); ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
This commit is contained in:
parent
7a21d264c7
commit
bcc496411b