fs-util: move link_fd() from tmpfile-util.c into generic fs-util.c

It's a generically useful call, let's move it so that we can use it at
more places.
This commit is contained in:
Lennart Poettering
2024-03-14 09:17:46 +01:00
parent dd92ba8a7a
commit 0b8e36f064
3 changed files with 22 additions and 20 deletions
+2
View File
@@ -146,3 +146,5 @@ int xopenat_lock_full(int dir_fd, const char *path, int open_flags, XOpenFlags x
static inline int xopenat_lock(int dir_fd, const char *path, int open_flags, LockType locktype, int operation) {
return xopenat_lock_full(dir_fd, path, open_flags, 0, 0, locktype, operation);
}
int link_fd(int fd, int newdirfd, const char *newpath);