X-Git-Url: https://www.chiark.greenend.org.uk/ucgi/~ianmdlvl/git?a=blobdiff_plain;f=src%2Flabel.c;h=43f6e89fa5a1e22bdf30f39195c523ece3714f37;hb=f8e08a77e7bbea802b50adcb442f99af462fa96e;hp=09ded642fb1d51003230b09e41e484ae0dd48209;hpb=c904f64d84db8c4eebedf210ba10893f19ba05ed;p=elogind.git diff --git a/src/label.c b/src/label.c index 09ded642f..43f6e89fa 100644 --- a/src/label.c +++ b/src/label.c @@ -90,14 +90,14 @@ int label_fix(const char *path, bool ignore_enoent) { /* If the FS doesn't support labels, then exit without warning */ if (r < 0 && errno == ENOTSUP) return 0; - - /* Ignore ENOENT in some cases */ - if (r < 0 && ignore_enoent && errno == ENOENT) - return 0; } } if (r < 0) { + /* Ignore ENOENT in some cases */ + if (ignore_enoent && errno == ENOENT) + return 0; + log_full(security_getenforce() == 1 ? LOG_ERR : LOG_DEBUG, "Unable to fix label of %s: %m", path); r = security_getenforce() == 1 ? -errno : 0;