X-Git-Url: http://www.chiark.greenend.org.uk/ucgi/~ianmdlvl/git?a=blobdiff_plain;f=src%2Flabel.c;h=2c887a0fe52194ac3775966d3af6840d67a1f85d;hb=1124fe6f01b1d59d016c238026f20380f38d98dc;hp=3df7e55ba41316c2d44959dba238f2f1f2513354;hpb=382241ee56849bd358047e7970d1ccf1ffec82a4;p=elogind.git diff --git a/src/label.c b/src/label.c index 3df7e55ba..2c887a0fe 100644 --- a/src/label.c +++ b/src/label.c @@ -109,7 +109,7 @@ int label_fix(const char *path, bool ignore_enoent) { return 0; if (r == 0) { - r = setfilecon(path, fcon); + r = lsetfilecon(path, fcon); freecon(fcon); /* If the FS doesn't support labels, then exit without warning */ @@ -291,7 +291,7 @@ int label_mkdir(const char *path, mode_t mode) { int r; security_context_t fcon = NULL; - if (!use_selinux() || label_hnd) + if (!use_selinux() || !label_hnd) goto skipped; if (path_is_absolute(path))