summaryrefslogtreecommitdiffstats
path: root/hw/i386
diff options
context:
space:
mode:
authorAlex Chen2020-11-25 02:30:55 +0100
committerMichael S. Tsirkin2020-12-08 19:48:57 +0100
commit81ee17aa461d1bf05a45dddd7f9abfa9ab0b2036 (patch)
tree2e4ccb41f2d3e69374ab9c55c8e00158347d4e89 /hw/i386
parentUpdate version for v5.2.0 release (diff)
downloadqemu-81ee17aa461d1bf05a45dddd7f9abfa9ab0b2036.tar.gz
qemu-81ee17aa461d1bf05a45dddd7f9abfa9ab0b2036.tar.xz
qemu-81ee17aa461d1bf05a45dddd7f9abfa9ab0b2036.zip
vhost-user-scsi: Fix memleaks in vus_proc_req()
The 'elem' is allocated memory in vu_queue_pop(), and its memory should be freed in all error branches after vu_queue_pop(). In addition, in order to free the 'elem' memory outside of while(1) loop, move the definition of 'elem' to the beginning of vus_proc_req(). Reported-by: Euler Robot <euler.robot@huawei.com> Signed-off-by: Alex Chen <alex.chen@huawei.com> Reviewed-by: Raphael Norwitz <raphael.norwitz@nutanix.com> Message-Id: <20201125013055.34147-1-alex.chen@huawei.com> Reviewed-by: Michael S. Tsirkin <mst@redhat.com> Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Diffstat (limited to 'hw/i386')
0 files changed, 0 insertions, 0 deletions