mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-06 17:23:56 -06:00
vhost: put log correctly in vhost_dev_start()
We allocate an dummy log even if the size is zero. So we should put it unconditionally too. Signed-off-by: Jason Wang <jasowang@redhat.com> Reviewed-by: Michael S. Tsirkin <mst@redhat.com> Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
This commit is contained in:
parent
309750fad5
commit
24bfa207ef
1 changed files with 1 additions and 3 deletions
|
@ -1111,9 +1111,7 @@ int vhost_dev_start(struct vhost_dev *hdev, VirtIODevice *vdev)
|
|||
|
||||
return 0;
|
||||
fail_log:
|
||||
if (hdev->log_size) {
|
||||
vhost_log_put(hdev, false);
|
||||
}
|
||||
vhost_log_put(hdev, false);
|
||||
fail_vq:
|
||||
while (--i >= 0) {
|
||||
vhost_virtqueue_stop(hdev,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue