virtio-gpu: fix memory leak in resource attach backing
commit204f01b30975923c64006f8067f0937b91eea68b
authorLi Qiang <liq3ea@gmail.com>
Thu, 29 Dec 2016 09:28:41 +0000 (29 04:28 -0500)
committerGerd Hoffmann <kraxel@redhat.com>
Tue, 3 Jan 2017 14:47:21 +0000 (3 15:47 +0100)
treee1161dddcc370f5045b9d7e3e32890653466a79d
parent33243031dad02d161225ba99d782616da133f689
virtio-gpu: fix memory leak in resource attach backing

In the resource attach backing function, everytime it will
allocate 'res->iov' thus can leading a memory leak. This
patch avoid this.

Signed-off-by: Li Qiang <liq3ea@gmail.com>
Message-id: 1483003721-65360-1-git-send-email-liq3ea@gmail.com
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
hw/display/virtio-gpu.c