diff options
| author | David Wei <dw@davidwei.uk> | 2025-05-03 07:30:50 +0300 |
|---|---|---|
| committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2025-05-29 12:03:12 +0300 |
| commit | 511ea82e344e044aad215a4456ab400a70565e54 (patch) | |
| tree | 87e4fb0421fd63ae87a625f157df6dfc997fea52 /io_uring | |
| parent | 6e9770de024964b1017f99ee94f71967bd6edaeb (diff) | |
| download | linux-511ea82e344e044aad215a4456ab400a70565e54.tar.xz | |
tools: ynl-gen: validate 0 len strings from kernel
[ Upstream commit 4720f9707c783f642332dee3d56dccaefa850e42 ]
Strings from the kernel are guaranteed to be null terminated and
ynl_attr_validate() checks for this. But it doesn't check if the string
has a len of 0, which would cause problems when trying to access
data[len - 1]. Fix this by checking that len is positive.
Signed-off-by: David Wei <dw@davidwei.uk>
Link: https://patch.msgid.link/20250503043050.861238-1-dw@davidwei.uk
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
Diffstat (limited to 'io_uring')
0 files changed, 0 insertions, 0 deletions
