]> git.ipfire.org Git - thirdparty/systemd.git/commit - src/basic/fd-util.c
fd-util: introduce fd_reopen() helper for reopening an fd
authorLennart Poettering <lennart@poettering.net>
Mon, 26 Mar 2018 11:25:51 +0000 (13:25 +0200)
committerLennart Poettering <lennart@poettering.net>
Thu, 29 Mar 2018 13:33:12 +0000 (15:33 +0200)
commitf2324783ceee84fbd24fd66f34d379fa1e6dc887
tree8a11285a10b7aa91d3cebb407c2dc66c3be60401
parentc75436067f4b392ecf161e123279720dc5c3b33a
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..
src/basic/fd-util.c
src/basic/fd-util.h
src/test/test-fs-util.c
src/tmpfiles/tmpfiles.c