diff --git a/src/security/security_manager.c b/src/security/security_manager.c index 0a43458d78..8bf1fcc342 100644 --- a/src/security/security_manager.c +++ b/src/security/security_manager.c @@ -296,10 +296,12 @@ int virSecurityManagerGenLabel(virSecurityManagerPtr mgr, virDomainDefPtr vm) { if (vm->seclabel.type == VIR_DOMAIN_SECLABEL_DEFAULT) { - if (mgr->defaultConfined) + if (mgr->defaultConfined) { vm->seclabel.type = VIR_DOMAIN_SECLABEL_DYNAMIC; - else + } else { vm->seclabel.type = VIR_DOMAIN_SECLABEL_NONE; + vm->seclabel.norelabel = true; + } } if ((vm->seclabel.type == VIR_DOMAIN_SECLABEL_NONE) &&