提交 eb8382fa 编写于 作者: G Guido Günther 提交者: Cole Robinson

selinux: fix compile errors

Remove unused variable, tag unused parameter and adjust return type.

introduced by 3f48345f

CC     security/libvirt_security_manager_la-security_selinux.lo
security/security_selinux.c: In function 'virSecuritySELinuxDomainSetDirLabel':
security/security_selinux.c:2520:5: error: return makes pointer from integer without a cast [-Werror]
security/security_selinux.c:2514:9: error: unused variable 'ret' [-Werror=unused-variable]
security/security_selinux.c:2509:59: error: unused parameter 'mgr' [-Werror=unused-parameter]

(cherry picked from commit 4d4c90df)
上级 82dce087
...@@ -2506,13 +2506,12 @@ virSecuritySELinuxGetSecurityMountOptions(virSecurityManagerPtr mgr, ...@@ -2506,13 +2506,12 @@ virSecuritySELinuxGetSecurityMountOptions(virSecurityManagerPtr mgr,
return opts; return opts;
} }
static char * static int
virSecuritySELinuxDomainSetDirLabel(virSecurityManagerPtr mgr, virSecuritySELinuxDomainSetDirLabel(virSecurityManagerPtr mgr ATTRIBUTE_UNUSED,
virDomainDefPtr def, virDomainDefPtr def,
const char *path) const char *path)
{ {
virSecurityLabelDefPtr seclabel; virSecurityLabelDefPtr seclabel;
int ret = -1;
seclabel = virDomainDefGetSecurityLabelDef(def, SECURITY_SELINUX_NAME); seclabel = virDomainDefGetSecurityLabelDef(def, SECURITY_SELINUX_NAME);
if (!seclabel || !seclabel->relabel) if (!seclabel || !seclabel->relabel)
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册