[libvirt PATCH 2/6] qemu: record deprecation messages against the domain

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

 



These messages are only valid while the domain is running.

Signed-off-by: Daniel P. Berrangé <berrange@xxxxxxxxxx>
---
 src/qemu/qemu_domain.c  | 5 +++++
 src/qemu/qemu_process.c | 5 +++++
 2 files changed, 10 insertions(+)

diff --git a/src/qemu/qemu_domain.c b/src/qemu/qemu_domain.c
index 0f09e321fb..d362764060 100644
--- a/src/qemu/qemu_domain.c
+++ b/src/qemu/qemu_domain.c
@@ -6236,6 +6236,11 @@ void qemuDomainObjTaintMsg(virQEMUDriverPtr driver,
         va_end(args);
     }
 
+    if (taint == VIR_DOMAIN_TAINT_DEPRECATED_CONFIG &&
+        extramsg) {
+        virDomainObjDeprecation(obj, extramsg);
+    }
+
     VIR_WARN("Domain id=%d name='%s' uuid=%s is tainted: %s%s%s%s",
              obj->def->id,
              obj->def->name,
diff --git a/src/qemu/qemu_process.c b/src/qemu/qemu_process.c
index 30cfa4d485..91f74b95bb 100644
--- a/src/qemu/qemu_process.c
+++ b/src/qemu/qemu_process.c
@@ -7857,6 +7857,11 @@ void qemuProcessStop(virQEMUDriverPtr driver,
         }
     }
 
+    for (i = 0; i < vm->ndeprecations; i++)
+        g_free(vm->deprecations[i]);
+    g_free(vm->deprecations);
+    vm->ndeprecations = 0;
+    vm->deprecations = NULL;
     vm->taint = 0;
     vm->pid = -1;
     virDomainObjSetState(vm, VIR_DOMAIN_SHUTOFF, reason);
-- 
2.29.2




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

  Powered by Linux