]> Gentwo Git Trees - linux/.git/commit
s390/sysinfo: Replace sprintf() with snprintf() for buffer safety
authorJosephine Pfeiffer <hi@josie.lol>
Wed, 1 Oct 2025 17:41:04 +0000 (19:41 +0200)
committerHeiko Carstens <hca@linux.ibm.com>
Tue, 21 Oct 2025 08:17:29 +0000 (10:17 +0200)
commit4738e1166260fd812faf5fef624b0f9308d8c4d4
tree9d70b605d64b6f03c64e6a207aefa5360259e9f2
parent5379879a76e25998d56c2136fef7d67eae33418f
s390/sysinfo: Replace sprintf() with snprintf() for buffer safety

Replace sprintf() with snprintf() when formatting symlink target name
to prevent potential buffer overflow. The link_to buffer is only 10
bytes, and using snprintf() ensures proper bounds checking if the
topology nesting limit value is unexpectedly large.

Signed-off-by: Josephine Pfeiffer <hi@josie.lol>
Signed-off-by: Heiko Carstens <hca@linux.ibm.com>
arch/s390/kernel/sysinfo.c