From b9bbdb8ae401dea58c56845fceb6b615225df6b4 Mon Sep 17 00:00:00 2001 From: Michael Jeanson Date: Wed, 4 Nov 2020 10:04:12 -0500 Subject: [PATCH] port: FreeBSD does support fchown and fchmod on a shm fd MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Signed-off-by: Michael Jeanson Signed-off-by: Jérémie Galarneau Change-Id: Iadff886d593ae3f77a4e96dfbfe02d1c1ea45f1e --- src/bin/lttng-sessiond/shm.c | 4 ---- 1 file changed, 4 deletions(-) diff --git a/src/bin/lttng-sessiond/shm.c b/src/bin/lttng-sessiond/shm.c index 1fc07dbd3..8b7744221 100644 --- a/src/bin/lttng-sessiond/shm.c +++ b/src/bin/lttng-sessiond/shm.c @@ -106,7 +106,6 @@ static int get_wait_shm(char *shm_path, size_t mmap_size, int global) exit(EXIT_FAILURE); } -#ifndef __FreeBSD__ if (global) { ret = fchown(wait_shm_fd, 0, 0); if (ret < 0) { @@ -131,9 +130,6 @@ static int get_wait_shm(char *shm_path, size_t mmap_size, int global) exit(EXIT_FAILURE); } } -#else -#warning "FreeBSD does not support setting file mode on shm FD." -#endif DBG("Got the wait shm fd %d", wait_shm_fd); -- 2.34.1