fs-util: also add an at_flags_normalize_follow() helper

This is the reverse of at_flags_normalize_follow()
This commit is contained in:
Lennart Poettering
2025-01-22 17:46:50 +01:00
parent 0783d8da50
commit 4b11087b37
2 changed files with 10 additions and 1 deletions
+1 -1
View File
@@ -298,7 +298,7 @@ int inode_same_at(int fda, const char *filea, int fdb, const char *fileb, int fl
flags |= AT_EMPTY_PATH;
}
int ntha_flags = (flags & AT_EMPTY_PATH) | (FLAGS_SET(flags, AT_SYMLINK_NOFOLLOW) ? 0 : AT_SYMLINK_FOLLOW);
int ntha_flags = at_flags_normalize_follow(flags) & (AT_EMPTY_PATH|AT_SYMLINK_FOLLOW);
_cleanup_free_ struct file_handle *ha = NULL, *hb = NULL;
int mntida = -1, mntidb = -1;