[PATCH v2 02/15] qemu: Move 'done' label in qemuBuildControllerDevStr()

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Even when we skip part of the processing, we still want error
checking on the buffer.

Signed-off-by: Andrea Bolognani <abologna@xxxxxxxxxx>
---
 src/qemu/qemu_command.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/qemu/qemu_command.c b/src/qemu/qemu_command.c
index 55e573b61..1ab5b0818 100644
--- a/src/qemu/qemu_command.c
+++ b/src/qemu/qemu_command.c
@@ -2801,10 +2801,10 @@ qemuBuildControllerDevStr(const virDomainDef *domainDef,
     if (qemuBuildDeviceAddressStr(&buf, domainDef, &def->info, qemuCaps) < 0)
         goto error;
 
+ done:
     if (virBufferCheckError(&buf) < 0)
         goto error;
 
- done:
     *devstr = virBufferContentAndReset(&buf);
     return 0;
 
-- 
2.14.3

--
libvir-list mailing list
libvir-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/libvir-list



[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]

  Powered by Linux