Re: [PATCH] vhost: fix repeated memory unmap in error paths

2022-02-10 Thread Konstantin Khlebnikov
10.02.2022, 15:06, "Philippe Mathieu-Daudé" :On 10/2/22 12:46, Konstantin Khlebnikov wrote: Fuzzing found that on some error paths vhost_memory_unmap() is called twice or for NULL address. Let's reset pointers after unmap and ingnore unmap for NULL.  Signed-off-by: Konstantin Khlebnikov

Re: [PATCH] vhost: fix repeated memory unmap in error paths

2022-02-10 Thread Philippe Mathieu-Daudé via
On 10/2/22 12:46, Konstantin Khlebnikov wrote: Fuzzing found that on some error paths vhost_memory_unmap() is called twice or for NULL address. Let's reset pointers after unmap and ingnore unmap for NULL. Signed-off-by: Konstantin Khlebnikov --- hw/virtio/vhost.c |4 +++- 1 file changed,

[PATCH] vhost: fix repeated memory unmap in error paths

2022-02-10 Thread Konstantin Khlebnikov
Fuzzing found that on some error paths vhost_memory_unmap() is called twice or for NULL address. Let's reset pointers after unmap and ingnore unmap for NULL. Signed-off-by: Konstantin Khlebnikov --- hw/virtio/vhost.c |4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/hw/vi