)
AX_CONFIG_FEATURE(
[dirfd], [Use directory file descriptors],
- [COMPAT_DIRFD], [This platform supports directory file descriptors.],
- [enable_dirfd="yes"], [enable_dirfd="no"]
+ [HAVE_DIRFD], [This platform supports directory file descriptors.]
)
-AM_CONDITIONAL([COMPAT_DIRFD], [ test "$enable_dirfd" = "yes" ])
AM_CONDITIONAL([TEST_JAVA_JUL_AGENT], [test "x$test_java_agent_jul" = "xyes"])
AM_CONDITIONAL([TEST_JAVA_LOG4J_AGENT], [test "x$test_java_agent_log4j" = "xyes"])
static
void lttng_directory_handle_release(struct urcu_ref *ref);
-#ifdef COMPAT_DIRFD
+#ifdef HAVE_DIRFD
/*
* Special inode number reserved to represent the "current working directory".
return run_as_rmdirat_recursive(handle->dirfd, name, uid, gid, flags);
}
-#else /* COMPAT_DIRFD */
+#else /* HAVE_DIRFD */
static
int get_full_path(const struct lttng_directory_handle *handle,
return ret;
}
-#endif /* COMPAT_DIRFD */
+#endif /* HAVE_DIRFD */
/* Common implementation. */
* This wrapper provides a handle that is either a copy of a directory's path
* or a directory file descriptors, depending on the platform's capabilities.
*/
-#ifdef COMPAT_DIRFD
+#ifdef HAVE_DIRFD
struct lttng_directory_handle;
if (!lttng_directory_handle_uses_fd(new_handle)) {
ret = ENOTSUP;
} else {
-#ifdef COMPAT_DIRFD
+#ifdef HAVE_DIRFD
*out_fds = new_handle->dirfd;
#else
abort();
return ret;
}
-#ifdef COMPAT_DIRFD
+#ifdef HAVE_DIRFD
static
int fd_close(void *unused, int *in_fds)
{
}
new_handle = open_args.ret_handle;
-#ifdef COMPAT_DIRFD
+#ifdef HAVE_DIRFD
new_handle->destroy_cb = directory_handle_destroy;
new_handle->destroy_cb_data = tracker;
#endif