diff options
author | Akihiko Odaki <akihiko.odaki@daynix.com> | 2025-01-08 20:31:46 +0900 |
---|---|---|
committer | David Woodhouse <dwmw@amazon.co.uk> | 2025-01-09 10:43:13 +0000 |
commit | b6014c5089a313ac84fe74970eee56e3fc87b49b (patch) | |
tree | 6fbe8e3b1bdefde9e6921ab25cd26f46f39cc393 /docs/system/_templates | |
parent | 981780cdda5a60ae7ae319933673ff9475245965 (diff) | |
download | qemu-b6014c5089a313ac84fe74970eee56e3fc87b49b.zip qemu-b6014c5089a313ac84fe74970eee56e3fc87b49b.tar.gz qemu-b6014c5089a313ac84fe74970eee56e3fc87b49b.tar.bz2 |
hw/xen: Check if len is 0 before memcpy()
data->data can be NULL when len is 0. Strictly speaking, the behavior
of memcpy() in such a scenario is undefined so UBSan complaints.
Satisfy UBSan by checking if len is 0 before memcpy().
Signed-off-by: Akihiko Odaki <akihiko.odaki@daynix.com>
Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Signed-off-by: David Woodhouse <dwmw@amazon.co.uk>
Diffstat (limited to 'docs/system/_templates')
0 files changed, 0 insertions, 0 deletions