summaryrefslogtreecommitdiffstats
path: root/linux/SELinuxMeter.c
diff options
context:
space:
mode:
authorChristian Göttsche <cgzones@googlemail.com>2020-12-17 16:53:59 +0100
committerChristian Göttsche <cgzones@googlemail.com>2021-01-11 23:45:47 +0100
commit960f52b78357dad25e36f624dfbff91e4c6b4bc2 (patch)
treef5120f014f6ef8b3c031d7b1db8c974d8b4edbf9 /linux/SELinuxMeter.c
parente6d536dd3f12bc7f5c56062a008d5c17e3417fa8 (diff)
SELinuxMeter: hardcode SELINUX_MAGIC value
Avoid <linux/magic.h> include, not found by musl-gcc. The value of SELINUX_MAGIC should really never change.
Diffstat (limited to 'linux/SELinuxMeter.c')
-rw-r--r--linux/SELinuxMeter.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/linux/SELinuxMeter.c b/linux/SELinuxMeter.c
index 892f1e82..c9fa1468 100644
--- a/linux/SELinuxMeter.c
+++ b/linux/SELinuxMeter.c
@@ -12,7 +12,6 @@ in the source distribution for its full text.
#include <stdbool.h>
#include <stdio.h>
#include <unistd.h>
-#include <linux/magic.h>
#include <sys/statfs.h>
#include <sys/statvfs.h>
@@ -35,7 +34,7 @@ static bool hasSELinuxMount(void) {
return false;
}
- if ((uint32_t)sfbuf.f_type != (uint32_t)SELINUX_MAGIC) {
+ if ((uint32_t)sfbuf.f_type != /* SELINUX_MAGIC */ 0xf97cff8cU) {
return false;
}

© 2014-2024 Faster IT GmbH | imprint | privacy policy