android_kernel_samsung_univ.../scripts/kconfig
Nathan Chancellor 3165890915 kconfig: Avoid format overflow warning from GCC 8.1
commit 2ae89c7a82ea9d81a19b4fc2df23bef4b112f24e upstream.

In file included from scripts/kconfig/zconf.tab.c:2485:
scripts/kconfig/confdata.c: In function ‘conf_write’:
scripts/kconfig/confdata.c:773:22: warning: ‘%s’ directive writing likely 7 or more bytes into a region of size between 1 and 4097 [-Wformat-overflow=]
  sprintf(newname, "%s%s", dirname, basename);
                      ^~
scripts/kconfig/confdata.c:773:19: note: assuming directive output of 7 bytes
  sprintf(newname, "%s%s", dirname, basename);
                   ^~~~~~
scripts/kconfig/confdata.c:773:2: note: ‘sprintf’ output 1 or more bytes (assuming 4104) into a destination of size 4097
  sprintf(newname, "%s%s", dirname, basename);
  ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
scripts/kconfig/confdata.c:776:23: warning: ‘.tmpconfig.’ directive writing 11 bytes into a region of size between 1 and 4097 [-Wformat-overflow=]
   sprintf(tmpname, "%s.tmpconfig.%d", dirname, (int)getpid());
                       ^~~~~~~~~~~
scripts/kconfig/confdata.c:776:3: note: ‘sprintf’ output between 13 and 4119 bytes into a destination of size 4097
   sprintf(tmpname, "%s.tmpconfig.%d", dirname, (int)getpid());
   ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Increase the size of tmpname and newname to make GCC happy.

Signed-off-by: Nathan Chancellor <natechancellor@gmail.com>
Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-06-13 16:15:27 +02:00
..
lxdialog
.gitignore
check.sh
conf.c
confdata.c kconfig: Avoid format overflow warning from GCC 8.1 2018-06-13 16:15:27 +02:00
expr.c kconfig: Fix expr_free() E_NOT leak 2018-05-30 07:48:53 +02:00
expr.h
gconf.c
gconf.glade
images.c
kxgettext.c
list.h
lkc_proto.h
lkc.h
Makefile scripts/kconfig: allow building with make 3.80 again 2016-04-12 09:09:00 -07:00
mconf.c
menu.c kconfig: Fix automatic menu creation mem leak 2018-05-30 07:48:53 +02:00
merge_config.sh kconfig/merge_config.sh: Accept a single file 2015-10-14 16:19:37 +02:00
nconf.c
nconf.gui.c kconfig/nconf: Fix hang when editing symbol with a long prompt 2017-01-09 08:07:53 +01:00
nconf.h
POTFILES.in
qconf.cc Add current selection check. 2015-11-02 21:43:58 +01:00
qconf.h Port xconfig to Qt5 - Source format. 2015-10-14 14:59:03 +02:00
streamline_config.pl
symbol.c
util.c
zconf.gperf
zconf.hash.c_shipped
zconf.l
zconf.lex.c_shipped
zconf.tab.c_shipped
zconf.y kconfig: Don't leak main menus during parsing 2018-05-30 07:48:53 +02:00