1
0
mirror of https://gitlab.com/libvirt/libvirt.git synced 2025-03-20 07:59:00 +00:00

Fixed connection definition for non-SELinux builds

This patch fixes the access of variable "con" in two files where the
variable was declared only on SELinux builds and thus the build failed
without SELinux. It's a rather nasty fix but helps fix the build
quickly and without any major changes to the code.
This commit is contained in:
Martin Kletzander 2012-02-03 16:03:18 +01:00 committed by Michal Privoznik
parent 3d93706d0d
commit 32f881c6c4
2 changed files with 4 additions and 0 deletions

View File

@ -449,6 +449,8 @@ static int lxcContainerMountBasicFS(const char *srcprefix, bool pivotRoot)
char *opts = NULL;
#if HAVE_SELINUX
security_context_t con;
#else
bool con = false;
#endif
VIR_DEBUG("Mounting basic filesystems %s pivotRoot=%d", NULLSTR(srcprefix), pivotRoot);

View File

@ -1438,6 +1438,8 @@ lxcControllerRun(virDomainDefPtr def,
if (root) {
#if HAVE_SELINUX
security_context_t con;
#else
bool con = false;
#endif
char *opts;
VIR_DEBUG("Setting up private /dev/pts");