summaryrefslogtreecommitdiff
path: root/src/shutdown
diff options
context:
space:
mode:
authorLennart Poettering <lennart@poettering.net>2023-01-10 12:09:58 +0100
committerLennart Poettering <lennart@poettering.net>2023-01-10 14:51:46 +0100
commit9914ae60382176b6a09c6226e8e90ab7184e8431 (patch)
tree710fb1049b9fd81df904c6a3afb06de18516fba7 /src/shutdown
parent9b87ccd4ab02978e6966199ea126a3e7bffc0462 (diff)
downloadsystemd-9914ae60382176b6a09c6226e8e90ab7184e8431.tar.gz
shutdown: don't close pipe fds.
Man, I royally screwed this one up! 😳 Fixes: #25998
Diffstat (limited to 'src/shutdown')
-rw-r--r--src/shutdown/umount.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/shutdown/umount.c b/src/shutdown/umount.c
index dc662a5812..1326b32f6a 100644
--- a/src/shutdown/umount.c
+++ b/src/shutdown/umount.c
@@ -608,7 +608,7 @@ static int remount_with_timeout(MountPoint *m, bool last_try) {
/* Due to the possibility of a remount operation hanging, we fork a child process and set a
* timeout. If the timeout lapses, the assumption is that the particular remount failed. */
- r = safe_fork("(sd-remount)", FORK_RESET_SIGNALS|FORK_CLOSE_ALL_FDS|FORK_LOG|FORK_REOPEN_LOG, &pid);
+ r = safe_fork_full("(sd-remount)", pfd, ELEMENTSOF(pfd), FORK_RESET_SIGNALS|FORK_CLOSE_ALL_FDS|FORK_LOG|FORK_REOPEN_LOG, &pid);
if (r < 0)
return r;
if (r == 0) {
@@ -661,7 +661,7 @@ static int umount_with_timeout(MountPoint *m, bool last_try) {
/* Due to the possibility of a umount operation hanging, we fork a child process and set a
* timeout. If the timeout lapses, the assumption is that the particular umount failed. */
- r = safe_fork("(sd-umount)", FORK_RESET_SIGNALS|FORK_CLOSE_ALL_FDS|FORK_LOG|FORK_REOPEN_LOG, &pid);
+ r = safe_fork_full("(sd-umount)", pfd, ELEMENTSOF(pfd), FORK_RESET_SIGNALS|FORK_CLOSE_ALL_FDS|FORK_LOG|FORK_REOPEN_LOG, &pid);
if (r < 0)
return r;
if (r == 0) {