Use an empty string to let qemu fill out the default. https://bugzilla.redhat.com/show_bug.cgi?id=1454671 --- src/qemu/qemu_monitor_json.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/qemu/qemu_monitor_json.c b/src/qemu/qemu_monitor_json.c index 63b855920..c63d250d3 100644 --- a/src/qemu/qemu_monitor_json.c +++ b/src/qemu/qemu_monitor_json.c @@ -6522,7 +6522,10 @@ qemuMonitorJSONAttachCharDevCommand(const char *chrID, case VIR_DOMAIN_CHR_TYPE_UDP: backend_type = "udp"; - addr = qemuMonitorJSONBuildInetSocketAddress(chr->data.udp.connectHost, + host = chr->data.udp.connectHost; + if (!host) + host = ""; + addr = qemuMonitorJSONBuildInetSocketAddress(host, chr->data.udp.connectService); if (!addr || virJSONValueObjectAppend(data, "remote", addr) < 0) -- 2.13.0 -- libvir-list mailing list libvir-list@xxxxxxxxxx https://www.redhat.com/mailman/listinfo/libvir-list