1
0
Fork 0
alistair23-linux/scripts/kconfig
Nathan Chancellor 2ae89c7a82 kconfig: Avoid format overflow warning from GCC 8.1
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.

Cc: stable@vger.kernel.org
Signed-off-by: Nathan Chancellor <natechancellor@gmail.com>
Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
2018-06-05 22:07:21 +09:00
..
lxdialog kconfig: drop localization support 2018-05-28 18:25:21 +09:00
tests kconfig: test: add Kconfig macro language tests 2018-05-29 03:31:19 +09:00
.gitignore kconfig: drop localization support 2018-05-28 18:25:21 +09:00
Makefile kbuild: Move last word of nconfig help to the previous line 2018-06-05 22:07:03 +09:00
conf.c kconfig: drop localization support 2018-05-28 18:25:21 +09:00
confdata.c kconfig: Avoid format overflow warning from GCC 8.1 2018-06-05 22:07:21 +09:00
expr.c kconfig: make unmet dependency warnings readable 2018-03-26 02:04:06 +09:00
expr.h kconfig: make unmet dependency warnings readable 2018-03-26 02:04:06 +09:00
gconf-cfg.sh kconfig: refactor GTK+ package checks for building gconf 2018-05-28 18:25:21 +09:00
gconf.c kconfig: drop localization support 2018-05-28 18:25:21 +09:00
gconf.glade scripts/kconfig/gconf.glade Update broken web addresses. 2010-09-17 16:54:42 +02:00
images.c Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
kconf_id.c kconfig: reference environment variables directly and remove 'option env=' 2018-05-29 03:28:58 +09:00
list.h License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
lkc.h kconfig: reference environment variables directly and remove 'option env=' 2018-05-29 03:28:58 +09:00
lkc_proto.h kconfig: support append assignment operator 2018-05-29 03:31:19 +09:00
mconf-cfg.sh kconfig: refactor ncurses package checks for building mconf and nconf 2018-05-28 18:25:21 +09:00
mconf.c kconfig: drop localization support 2018-05-28 18:25:21 +09:00
menu.c kconfig: reference environment variables directly and remove 'option env=' 2018-05-29 03:28:58 +09:00
merge_config.sh kconfig/merge_config.sh: Accept a single file 2015-10-14 16:19:37 +02:00
nconf-cfg.sh kconfig: refactor ncurses package checks for building mconf and nconf 2018-05-28 18:25:21 +09:00
nconf.c kconfig: drop localization support 2018-05-28 18:25:21 +09:00
nconf.gui.c kconfig: add xrealloc() helper 2018-02-10 11:26:04 +09:00
nconf.h kconfig: drop localization support 2018-05-28 18:25:21 +09:00
preprocess.c kconfig: error out if a recursive variable references itself 2018-05-29 03:31:19 +09:00
qconf-cfg.sh kconfig: refactor Qt package checks for building qconf 2018-05-28 18:25:21 +09:00
qconf.cc kconfig: drop localization support 2018-05-28 18:25:21 +09:00
qconf.h Port xconfig to Qt5 - Source format. 2015-10-14 14:59:03 +02:00
streamline_config.pl scripts: Switch to more portable Perl shebang 2017-05-14 11:20:44 +09:00
symbol.c kconfig: remove sym_expand_string_value() 2018-05-29 03:31:19 +09:00
util.c kconfig: remove string expansion in file_lookup() 2018-05-29 03:28:58 +09:00
zconf.l kconfig: expand lefthand side of assignment statement 2018-05-29 03:31:19 +09:00
zconf.y kconfig: support simply expanded variable 2018-05-29 03:31:19 +09:00