diff options
| author | Gabriele Monaco <gmonaco@redhat.com> | 2026-06-04 14:09:45 +0200 |
|---|---|---|
| committer | Gabriele Monaco <gmonaco@redhat.com> | 2026-06-04 16:43:43 +0200 |
| commit | 08904765bb941f98306ae6841c33cfd299343faf (patch) | |
| tree | 30f3c507ae7884aa9e3b4a4bc825ae83b2ffd32a /drivers/clk/aspeed/git@git.tavy.me:linux.git | |
| parent | d9022172c1abea9e220d13ee453813dafec5b9e4 (diff) | |
tools/rv: Ensure monitor name and desc are NUL-terminated
ikm_fill_monitor_definition() copies monitor name and description with
strncpy(), but does not guarantee NUL termination when source strings are
equal to or longer than the destination buffers.
Clamp copies to sizeof(dst) - 1 and explicitly append '\0' for both fields
to keep them safe for later string operations.
Suggested-by: unknownbbqrx <dev@unknownbbqr.xyz>
Fixes: 6d60f89691fc9 ("tools/rv: Add in-kernel monitor interface")
Link: https://lore.kernel.org/r/20260604120946.90302-2-gmonaco@redhat.com
Signed-off-by: Gabriele Monaco <gmonaco@redhat.com>
Diffstat (limited to 'drivers/clk/aspeed/git@git.tavy.me:linux.git')
0 files changed, 0 insertions, 0 deletions
