diff options
Diffstat (limited to 'lib/include')
-rw-r--r-- | lib/include/util.h | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/lib/include/util.h b/lib/include/util.h index 925a1f0..f300329 100644 --- a/lib/include/util.h +++ b/lib/include/util.h @@ -21,6 +21,7 @@ #include <sys/types.h> #include <stdbool.h> #include <stddef.h> +#include <stdio.h> #include "config.h" @@ -83,5 +84,11 @@ int setup_tty(const char *tty, bool truncate); NORETURN void argv_exec(exec_t *e); +/* + Similar to openat: opens a file relative to a dirfd, but returns + a FILE pointer instead of an fd. + */ +FILE *fopenat(int fd, const char *filename, const char *mode); + #endif /* UTIL_H */ |