summaryrefslogtreecommitdiffstats
path: root/linux
diff options
context:
space:
mode:
authorChris Burr <chrisburr@users.noreply.github.com>2020-12-12 11:41:15 +0100
committerBenny Baumann <BenBE@geshi.org>2020-12-13 00:55:50 +0100
commit8149823d56653b7d23397a235edb609b358ff17d (patch)
treefaaa24165b125bb214e254ec4cdb2aecaadf2bf1 /linux
parent880eecabf5251bca8b84012283bf377e672a6728 (diff)
Define O_PATH if not already defined
Diffstat (limited to 'linux')
-rw-r--r--linux/LinuxProcessList.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/linux/LinuxProcessList.c b/linux/LinuxProcessList.c
index e228220f..1dab5dbb 100644
--- a/linux/LinuxProcessList.c
+++ b/linux/LinuxProcessList.c
@@ -57,6 +57,12 @@ in the source distribution for its full text.
#endif
+// CentOS 6's kernel doesn't provide a definition of O_PATH
+// based on definition taken from uapi/asm-generic/fcnth.h in Linux kernel tree
+#ifndef O_PATH
+# define O_PATH 010000000
+#endif
+
static FILE* fopenat(openat_arg_t openatArg, const char* pathname, const char* mode) {
assert(String_eq(mode, "r")); /* only currently supported mode */

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