[libvirt PATCH] qemu_shim: set system identity

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

 



Otherwise looking up a secret fails when we try to elevate the identity
in qemuDomainSecretInfoSetupFromSecret.

https://bugzilla.redhat.com/show_bug.cgi?id=2000410

Signed-off-by: Ján Tomko <jtomko@xxxxxxxxxx>
---
 src/qemu/qemu_shim.c | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/src/qemu/qemu_shim.c b/src/qemu/qemu_shim.c
index 7b58583074..b642f6175a 100644
--- a/src/qemu/qemu_shim.c
+++ b/src/qemu/qemu_shim.c
@@ -26,6 +26,7 @@
 
 #include "virfile.h"
 #include "virgettext.h"
+#include "viridentity.h"
 #include "virthread.h"
 
 #define VIR_FROM_THIS VIR_FROM_QEMU
@@ -133,6 +134,7 @@ qemuShimQuench(void *userData G_GNUC_UNUSED,
 
 int main(int argc, char **argv)
 {
+    g_autoptr(virIdentity) sysident = NULL;
     GThread *eventLoopThread = NULL;
     virConnectPtr conn = NULL;
     virConnectPtr sconn = NULL;
@@ -191,6 +193,9 @@ int main(int argc, char **argv)
 
     virSetErrorFunc(NULL, qemuShimQuench);
 
+    sysident = virIdentityGetSystem();
+    virIdentitySetCurrent(sysident);
+
     if (verbose)
         g_printerr("%s: %lld: initializing signal handlers\n",
                    argv[0], deltams());
-- 
2.39.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