directory-handle: add an equals method
[lttng-tools.git] / src / common / compat / directory-handle.h
index 5974e36e35538cac553dd22daf81b1d24aba9410..0ad5c851072ab68de75788aeeb42c657dbd19e8c 100644 (file)
@@ -37,6 +37,7 @@ enum lttng_directory_handle_rmdir_recursive_flags {
 #ifdef COMPAT_DIRFD
 struct lttng_directory_handle {
        struct urcu_ref ref;
+       ino_t directory_inode;
        int dirfd;
 };
 
@@ -256,4 +257,13 @@ int lttng_directory_handle_remove_subdirectory_recursive_as_user(
                const struct lttng_credentials *creds,
                int flags);
 
+/*
+ * Compare two directory handles.
+ *
+ * Returns true if the two directory handles are equal, false otherwise.
+ */
+LTTNG_HIDDEN
+bool lttng_directory_handle_equals(const struct lttng_directory_handle *lhs,
+               const struct lttng_directory_handle *rhs);
+
 #endif /* _COMPAT_PATH_HANDLE_H */
This page took 0.023848 seconds and 5 git commands to generate.