]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
kconfig: qconf: fix buffer overflow in debug links
authorMasahiro Yamada <masahiroy@kernel.org>
Tue, 1 Oct 2024 09:02:22 +0000 (18:02 +0900)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 17 Oct 2024 13:11:43 +0000 (15:11 +0200)
commit3d5bce8a9f6fcdf597bc53dadc23e7c136416c99
tree7aa7aad3880fabd8319b8870aa4a3594c39569ce
parenteb9329cd882aa274e92bdb1003bc088433fdee86
kconfig: qconf: fix buffer overflow in debug links

[ Upstream commit 984ed20ece1c6c20789ece040cbff3eb1a388fa9 ]

If you enable "Option -> Show Debug Info" and click a link, the program
terminates with the following error:

    *** buffer overflow detected ***: terminated

The buffer overflow is caused by the following line:

    strcat(data, "$");

The buffer needs one more byte to accommodate the additional character.

Fixes: c4f7398bee9c ("kconfig: qconf: make debug links work again")
Signed-off-by: Masahiro Yamada <masahiroy@kernel.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
scripts/kconfig/qconf.cc