]> git.ipfire.org Git - thirdparty/systemd.git/commit - src/basic/fs-util.c
fs-util: use _cleanup_close_ attribute
authorYu Watanabe <watanabe.yu+github@gmail.com>
Sun, 21 Jan 2018 10:07:10 +0000 (19:07 +0900)
committerYu Watanabe <watanabe.yu+github@gmail.com>
Sun, 21 Jan 2018 10:07:14 +0000 (19:07 +0900)
commit2b6d2dda6b7eb2afb1df47df158b212abde2ef1c
treea9a5d644353c88ef29c95e74b85b669276780dfb
parent91ec71c1628bd347c85b3348b2d3b5f84f133b71
fs-util: use _cleanup_close_ attribute

The commit f14f1806e329fe92d01f15c22a384702f0cb4ae0 introduced CHASE_SAFE
flag. When the flag is set, then `fd_parent` may not be properly closed.
This sets `_cleanup_close_` attribute to `fd_parent`.
Thus, now `fd_parent` is always closed properly.
src/basic/fs-util.c