1
0
mirror of git://sourceware.org/git/lvm2.git synced 2025-02-23 13:57:47 +03:00

Don't abort operations if selinux is present but disabled.

This commit is contained in:
Alasdair Kergon 2004-05-04 15:29:26 +00:00
parent 74583a91fe
commit 470a1e923c
2 changed files with 2 additions and 2 deletions

View File

@ -181,7 +181,7 @@ static int _mk_link(const char *dev_dir, const char *vg_name,
#ifdef HAVE_SELINUX
if (!set_selinux_context(lv_path)) {
log_sys_error("set_selinux_context", lv_path);
stack;
return 0;
}
#endif

View File

@ -24,7 +24,7 @@ int set_selinux_context(const char *path)
log_very_verbose("Setting SELinux context for %s", path);
if (is_selinux_enabled() <= 0)
return 0;
return 1;
if (matchpathcon(path, 0, &scontext) < 0) {
log_sys_error("matchpathcon", path);