fd-util: introduce fd_reopen() helper for reopening an fd
We have the same code for this in place at various locations, let's unify that. Also, let's repurpose test-fs-util.c as a test for this new helper cal..
This commit is contained in:
@@ -113,3 +113,5 @@ static inline int make_null_stdio(void) {
|
||||
(fd) = -1; \
|
||||
_fd_; \
|
||||
})
|
||||
|
||||
int fd_reopen(int fd, int flags);
|
||||
|
||||
Reference in New Issue
Block a user