diff options
author | Masahiro Yamada <yamada.masahiro@socionext.com> | 2018-01-28 18:41:23 +0900 |
---|---|---|
committer | Tom Rini <trini@konsulko.com> | 2018-01-29 12:50:13 -0500 |
commit | 1414e09b4f25f2ad5886f124024e10878feb75f0 (patch) | |
tree | 97a11f12e3df4c986547e65c73db24ef56ddc716 /README | |
parent | f39bfec230828a843bb53d0213709d47db1574df (diff) | |
download | u-boot-1414e09b4f25f2ad5886f124024e10878feb75f0.zip u-boot-1414e09b4f25f2ad5886f124024e10878feb75f0.tar.gz u-boot-1414e09b4f25f2ad5886f124024e10878feb75f0.tar.bz2 |
kconfig: revert change that was not needed for -Wformat-security
Recent GCC versions warn if the format string is not a literal
because the compiler cannot check the argument validity at compile
time.
Commit 192bc6948b02 ("Fix GCC format-security errors and convert
sprintfs.") blindly replaced sprintf() with strcpy(), including
many cases where the format parameter is a string literal.
For the kconfig change:
sprintf(header, " ");
..., here the format parameter is a string literal " ", so it is
definitely equivalent to:
strcpy(header, " ");
Of course, if the 'header' did not have enough length for containing
" ", it would be a security problem, but another problem. (in this
case, the 'header' is 4 byte length buffer, so it is not a problem at
all.)
The kconfig code is kept as synced with Linux as possible, but this
change made the code out-of-sync for nothing. Just reverting.
Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
Diffstat (limited to 'README')
0 files changed, 0 insertions, 0 deletions