]> git.ipfire.org Git - thirdparty/libvirt.git/commitdiff
* qemud/qemud.c: patch from Guido Günther fixing the place where
authorDaniel Veillard <veillard@redhat.com>
Wed, 30 Jul 2008 08:47:10 +0000 (08:47 +0000)
committerDaniel Veillard <veillard@redhat.com>
Wed, 30 Jul 2008 08:47:10 +0000 (08:47 +0000)
  config file check is done.
Daniel

ChangeLog
qemud/qemud.c

index d5eb4f93047b488e99b3162ef997e86ce2d059d3..cbb7760e746640d4360a6793d3bab195ee00caba 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+Wed Jul 30 10:45:41 CEST 2008 Daniel Veillard <veillard@redhat.com>
+
+       * qemud/qemud.c: patch from Guido Günther fixing the place where
+         config file check is done.
+
 Tue Jul 29 14:08:00 CEST 2008 Chris Lalancette <clalance@redhat.com>
 
        * src/qemu_conf.c: fix empty CD-ROM source device section
@@ -5,7 +10,7 @@ Tue Jul 29 14:08:00 CEST 2008 Chris Lalancette <clalance@redhat.com>
        tests/qemuxml2argvdata/qemuxml2argv-disk-cdrom-empty.xml,
        tests/qemuxml2argvdata/qemuxml2argv-disk-cdrom-empty.args: Add test
        for empty source CD-ROM device section
-               
+
 Tue Jul 29 10:41:30 CEST 2008 Daniel Veillard <veillard@redhat.com>
 
        * src/openvz_conf.c: fix compilation with new XPath interface
index 30557e1172f8773c09ed00db0232e831ee55293b..9da27d215a901a3ede7903af8a8d181c2ceaa777 100644 (file)
@@ -1912,6 +1912,14 @@ remoteReadConfigFile (struct qemud_server *server, const char *filename)
     char *unix_sock_rw_perms = NULL;
     char *unix_sock_group = NULL;
 
+#if HAVE_POLKIT
+    /* Change the default back to no auth for non-root */
+    if (getuid() != 0 && auth_unix_rw == REMOTE_AUTH_POLKIT)
+        auth_unix_rw = REMOTE_AUTH_NONE;
+    if (getuid() != 0 && auth_unix_ro == REMOTE_AUTH_POLKIT)
+        auth_unix_ro = REMOTE_AUTH_NONE;
+#endif
+
     /* Just check the file is readable before opening it, otherwise
      * libvirt emits an error.
      */
@@ -1926,14 +1934,6 @@ remoteReadConfigFile (struct qemud_server *server, const char *filename)
     GET_CONF_STR (conf, filename, tcp_port);
     GET_CONF_STR (conf, filename, listen_addr);
 
-#if HAVE_POLKIT
-    /* Change the default back to no auth for non-root */
-    if (getuid() != 0 && auth_unix_rw == REMOTE_AUTH_POLKIT)
-        auth_unix_rw = REMOTE_AUTH_NONE;
-    if (getuid() != 0 && auth_unix_ro == REMOTE_AUTH_POLKIT)
-        auth_unix_ro = REMOTE_AUTH_NONE;
-#endif
-
     if (remoteConfigGetAuth(conf, "auth_unix_rw", &auth_unix_rw, filename) < 0)
         goto free_and_fail;
 #if HAVE_POLKIT