virtio-gpu: fix memory leak in virtio_gpu_resource_create_2d
Hi,
vga patch queue with a virtio-gpu memory leak fix.#
please pull,
Gerd
The following changes since commit ede0cbeb7892bdf4a19128853a3a3c61a17fb068:
Merge remote-tracking branch 'remotes/armbru/tags/pull-qapi-2016-10-25' into staging (2016-10-25 17:03:11 +0100)
are available in the git repository at:
git://git.kraxel.org/qemu tags/pull-vga-20161027-1
for you to fetch changes up to cb3a0522b694cc5bb6424497b3f828ccd28fd1dd:
virtio-gpu: fix memory leak in virtio_gpu_resource_create_2d (2016-10-26 14:52:21 +0200)
----------------------------------------------------------------
virtio-gpu: fix memory leak in virtio_gpu_resource_create_2d
----------------------------------------------------------------
Li Qiang (1):
virtio-gpu: fix memory leak in virtio_gpu_resource_create_2d
hw/display/virtio-gpu.c | 1 + 1 file changed, 1 insertion(+)
From: Li Qiang <[email protected]>
In virtio gpu resource create dispatch, if the pixman format is zero it doesn't free the resource object allocated previously. Thus leading a host memory leak issue. This patch avoid this.
Message-id: [email protected]
--- hw/display/virtio-gpu.c | 1 + 1 file changed, 1 insertion(+)
hw/display/virtio-gpu.c +1 -0
@@ -333,6 +333,7 @@ static void virtio_gpu_resource_create_2d(VirtIOGPU *g,qemu_log_mask (LOG_GUEST_ERROR ,"%s: host couldn't handle guest format %d\n" , __func__, c2d.format); +g_free (res); cmd->error =VIRTIO_GPU_RESP_ERR_INVALID_PARAMETER ;return ; }
Signature · 1 line
1.8.3.1
Peter Maydell
AppliedQuoted 23 lines · Gerd Hoffmann
Hi,
vga patch queue with a virtio-gpu memory leak fix.#
please pull,
GerdThe following changes since commit
ede0cbeb7892bdf4a19128853a3a3c61a17fb068:Merge remote-tracking branch 'remotes/armbru/tags/pull-qapi-2016-10-25' into staging (2016-10-25 17:03:11 +0100)
are available in the git repository at:
git://git.kraxel.org/qemutags/pull-vga-20161027-1for you to fetch changes up to
cb3a0522b694cc5bb6424497b3f828ccd28fd1dd:virtio-gpu: fix memory leak in
virtio_gpu_resource_create_2d(2016-10-26 14:52:21 +0200)----------------------------------------------------------------
virtio-gpu: fix memory leak invirtio_gpu_resource_create_2d
Quoted 6 lines
----------------------------------------------------------------
Li Qiang (1):
virtio-gpu: fix memory leak invirtio_gpu_resource_create_2dhw/display/virtio-gpu.c | 1 + 1 file changed, 1 insertion(+)
Applied, thanks.
-- PMM