The function that formats the string for network drives would return error code but did not set the error message when called on storage source with VIR_STORAGE_NET_PROTOCOL_LAST or _NONE. Report an error in this case if it would ever be called in that way. --- src/qemu/qemu_command.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/qemu/qemu_command.c b/src/qemu/qemu_command.c index 7e6b95c..8dd7a76 100644 --- a/src/qemu/qemu_command.c +++ b/src/qemu/qemu_command.c @@ -3263,6 +3263,9 @@ qemuBuildNetworkDriveURI(virStorageSourcePtr src, case VIR_STORAGE_NET_PROTOCOL_LAST: case VIR_STORAGE_NET_PROTOCOL_NONE: + virReportError(VIR_ERR_INTERNAL_ERROR, + _("Unexpected network protocol '%s'"), + virStorageNetProtocolTypeToString(src->protocol)); goto cleanup; } -- 2.2.2 -- libvir-list mailing list libvir-list@xxxxxxxxxx https://www.redhat.com/mailman/listinfo/libvir-list