[libvirt] [PATCH] qemu: Use the proper string in qemuBlock...JSONSocketAddress()

Martin Kletzander posted 1 patch 6 years, 9 months ago
Patches applied successfully (tree, apply log)
git fetch https://github.com/patchew-project/libvirt tags/patchew/a7a791d8e8f784fee326c2b1a8b56e021852bfa0.1500293706.git.mkletzan@redhat.com
src/qemu/qemu_block.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
[libvirt] [PATCH] qemu: Use the proper string in qemuBlock...JSONSocketAddress()
Posted by Martin Kletzander 6 years, 9 months ago
Recent refactors made it so that the function may use uninitialized
pointer, but it actually wanted to use a different variable and value
at all.

Signed-off-by: Martin Kletzander <mkletzan@redhat.com>
---
 src/qemu/qemu_block.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/qemu/qemu_block.c b/src/qemu/qemu_block.c
index ccaf3261101d..93124c5ba486 100644
--- a/src/qemu/qemu_block.c
+++ b/src/qemu/qemu_block.c
@@ -482,7 +482,7 @@ qemuBlockStorageSourceBuildHostsJSONSocketAddress(virStorageSourcePtr src,
         case VIR_STORAGE_NET_HOST_TRANS_LAST:
             virReportError(VIR_ERR_INTERNAL_ERROR,
                            _("transport protocol '%s' is not yet supported"),
-                           transport);
+                           virStorageNetHostTransportTypeToString(host->transport));
             goto cleanup;
         }
 
-- 
2.13.3

--
libvir-list mailing list
libvir-list@redhat.com
https://www.redhat.com/mailman/listinfo/libvir-list
Re: [libvirt] [PATCH] qemu: Use the proper string in qemuBlock...JSONSocketAddress()
Posted by Peter Krempa 6 years, 9 months ago
On Mon, Jul 17, 2017 at 14:15:06 +0200, Martin Kletzander wrote:
> Recent refactors made it so that the function may use uninitialized
> pointer, but it actually wanted to use a different variable and value
> at all.
> 
> Signed-off-by: Martin Kletzander <mkletzan@redhat.com>
> ---
>  src/qemu/qemu_block.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)

Oops, ACK
--
libvir-list mailing list
libvir-list@redhat.com
https://www.redhat.com/mailman/listinfo/libvir-list