X-Git-Url: http://www.chiark.greenend.org.uk/ucgi/~ianmdlvl/git?a=blobdiff_plain;f=src%2Fshared%2Flabel.c;h=25a8b361b7c9c86e23139976e16acc910f717342;hb=2e78fa79bbaebb358d2657c397180d2d08d69b12;hp=3b7b86e8fadcd30a10aa246dd11ab5056e270d2b;hpb=590b6b9188e75ba46c42995984a1c2fa06adb6d6;p=elogind.git diff --git a/src/shared/label.c b/src/shared/label.c index 3b7b86e8f..25a8b361b 100644 --- a/src/shared/label.c +++ b/src/shared/label.c @@ -27,9 +27,7 @@ #include #include #include -#ifdef HAVE_XATTR #include -#endif #ifdef HAVE_SELINUX #include #include @@ -295,6 +293,8 @@ int label_socket_set(const char *label) { void label_context_clear(void) { #ifdef HAVE_SELINUX + PROTECT_ERRNO; + if (!use_selinux()) return; @@ -305,6 +305,8 @@ void label_context_clear(void) { void label_socket_clear(void) { #ifdef HAVE_SELINUX + PROTECT_ERRNO; + if (!use_selinux()) return;