summaryrefslogtreecommitdiffstats
path: root/external/meta-virtualization/recipes-extended/libvirt/libvirt/CVE-2019-3840.patch
blob: 8cca821626ce4a02eefeacfcea350357d57502df (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
From 9ed175fbc2deecfdaeabca7bc77c7e7ae33a3377 Mon Sep 17 00:00:00 2001
From: John Ferlan <jferlan@redhat.com>
Date: Fri, 7 Sep 2018 16:01:27 -0400
Subject: [PATCH] qemu: Remove duplicated qemuAgentCheckError

Commit 5b3492fadb moved qemuAgentCheckError calls into
qemuAgentCommand for various reasons; however, subsequent
commit 0977b8aa0 adding a new command made call again
So let's just remove the duplicitous call from
qemuAgentGetInterfaces.

Signed-off-by: John Ferlan <jferlan@redhat.com>
ACKed-by: Michal Privoznik <mprivozn@redhat.com>

Upstream-Status: Backport
CVE: CVE-2019-3840
Signed-off-by: Armin Kuster <akuster@mvista.com>

---
 src/qemu/qemu_agent.c | 5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)

Index: libvirt-4.7.0/src/qemu/qemu_agent.c
===================================================================
--- libvirt-4.7.0.orig/src/qemu/qemu_agent.c
+++ libvirt-4.7.0/src/qemu/qemu_agent.c
@@ -1987,10 +1987,9 @@ qemuAgentGetInterfaces(qemuAgentPtr mon,
     if (!(cmd = qemuAgentMakeCommand("guest-network-get-interfaces", NULL)))
         goto cleanup;
 
-    if (qemuAgentCommand(mon, cmd, &reply, false, VIR_DOMAIN_QEMU_AGENT_COMMAND_BLOCK) < 0 ||
-        qemuAgentCheckError(cmd, reply) < 0) {
+    if (qemuAgentCommand(mon, cmd, &reply, false,
+                         VIR_DOMAIN_QEMU_AGENT_COMMAND_BLOCK) < 0)
         goto cleanup;
-    }
 
     if (!(ret_array = virJSONValueObjectGet(reply, "return"))) {
         virReportError(VIR_ERR_INTERNAL_ERROR, "%s",