X-Git-Url: https://www.chiark.greenend.org.uk/ucgi/~ianmdlvl/git?p=elogind.git;a=blobdiff_plain;f=src%2Fshared%2Flabel.c;h=fde39f22594fd08ac1613818a25a29ecd4a65cef;hp=a8bf6bd4f93982ce46ba83edc28b982d01693def;hb=39bdfa31f2f00c3357e2a7a5f139abee6d7c7cd3;hpb=a5c32cff1f56afe6f0c6c70d91a88a7a8238b2d7 diff --git a/src/shared/label.c b/src/shared/label.c index a8bf6bd4f..fde39f225 100644 --- a/src/shared/label.c +++ b/src/shared/label.c @@ -82,7 +82,7 @@ int label_init(const char *prefix) { l = after_mallinfo.uordblks > before_mallinfo.uordblks ? after_mallinfo.uordblks - before_mallinfo.uordblks : 0; log_debug("Successfully loaded SELinux database in %s, size on heap is %iK.", - format_timespan(timespan, sizeof(timespan), after_timestamp - before_timestamp), + format_timespan(timespan, sizeof(timespan), after_timestamp - before_timestamp, 0), (l+1023)/1024); } #endif @@ -257,14 +257,14 @@ void label_free(const char *label) { #endif } -int label_mkdir(const char *path, mode_t mode, bool apply) { +int label_mkdir(const char *path, mode_t mode) { /* Creates a directory and labels it according to the SELinux policy */ #ifdef HAVE_SELINUX int r; security_context_t fcon = NULL; - if (!apply || !use_selinux() || !label_hnd) + if (!use_selinux() || !label_hnd) goto skipped; if (path_is_absolute(path))