]> git.ipfire.org Git - thirdparty/libvirt.git/commitdiff
Revert "Change label of fusefs mounted at /proc/meminfo in lxc containers"
authorDaniel P. Berrange <berrange@redhat.com>
Fri, 17 May 2013 09:22:54 +0000 (10:22 +0100)
committerDaniel P. Berrange <berrange@redhat.com>
Fri, 17 May 2013 09:22:54 +0000 (10:22 +0100)
This reverts commit 940c6f1085c3aafced51152b17a044af8c42b16e.

src/lxc/lxc_container.c

index 48ccc09a5b7e6cffb6e6b7c8fb36d58fa0aa6245..f877d8d8ed019843f260cf880dcf11875b04aaf9 100644 (file)
 # include <blkid/blkid.h>
 #endif
 
-#if WITH_SELINUX
-# include <selinux/selinux.h>
-#endif
-
 #include "virerror.h"
 #include "virlog.h"
 #include "lxc_container.h"
@@ -769,26 +765,6 @@ static int lxcContainerMountProcFuse(virDomainDefPtr def,
                            def->name)) < 0)
         return ret;
 
-# if WITH_SELINUX
-    if (is_selinux_enabled() > 0) {
-        security_context_t scon;
-        ret = getfilecon("/proc/meminfo", &scon);
-        if (ret < 0) {
-            virReportSystemError(errno,
-                                 _("Failed to get security context of %s for /proc/meminfo mount point"),
-                                 meminfo_path);
-            return ret;
-        }
-        ret = setfilecon(meminfo_path, scon);
-        freecon(scon);
-        if (ret < 0) {
-            virReportSystemError(errno,
-                                 _("Failed to set security context of %s for /proc/meminfo mount point"),
-                                 meminfo_path);
-            return ret;
-        }
-    }
-# endif
     if ((ret = mount(meminfo_path, "/proc/meminfo",
                      NULL, MS_BIND, NULL)) < 0) {
         virReportSystemError(errno,