[PATCH] qemu: Do not require auth scheme in graphics events

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

 



Only VNC_{{DIS,}CONNECTED,INITIALIZED} and SPICE_INITIALIZED events are
documented to support server/auth field and even there it is marked as
optional. Emit "" auth scheme in case QEMU didn't send it.
---
 src/qemu/qemu_monitor_json.c | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/src/qemu/qemu_monitor_json.c b/src/qemu/qemu_monitor_json.c
index 643431c..bab6ca2 100644
--- a/src/qemu/qemu_monitor_json.c
+++ b/src/qemu/qemu_monitor_json.c
@@ -685,8 +685,9 @@ static void qemuMonitorJSONHandleGraphics(qemuMonitorPtr mon, virJSONValuePtr da
 
     authScheme = virJSONValueObjectGetString(server, "auth");
     if (!authScheme) {
-        VIR_WARN("missing auth scheme in graphics event");
-        return;
+        /* not all events are required to contain auth scheme */
+        VIR_DEBUG("missing auth scheme in graphics event");
+        authScheme = "";
     }
 
     localFamily = virJSONValueObjectGetString(server, "family");
-- 
1.7.12

--
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]