summaryrefslogtreecommitdiff
path: root/src/shutdown.c
diff options
context:
space:
mode:
authorLennart Poettering <lennart@poettering.net>2010-10-26 20:51:15 +0200
committerLennart Poettering <lennart@poettering.net>2010-10-26 20:51:15 +0200
commit415dbd2e542e7a0f6b15350e1c5fd00dca54b91d (patch)
tree4357ac4befea47509936cd973fe37000ff71bf89 /src/shutdown.c
parent57b63f363ffeed8556da11eab395f902adcefd5b (diff)
shutdown: properly handle sigtimedwait() timing out
Diffstat (limited to 'src/shutdown.c')
-rw-r--r--src/shutdown.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/shutdown.c b/src/shutdown.c
index bd4b69bbe3..e8d2501792 100644
--- a/src/shutdown.c
+++ b/src/shutdown.c
@@ -140,7 +140,8 @@ static int send_signal(int sign) {
timespec_store(&ts, until - n);
if (sigtimedwait(&mask, NULL, &ts) != SIGCHLD)
- log_warning("Failed: sigtimedwait did not return SIGCHLD: %m");
+ if (errno != EAGAIN)
+ log_warning("Failed: sigtimedwait did not return SIGCHLD: %m");
}
finish:
@@ -189,7 +190,8 @@ static int rescue_send_signal(int sign) {
timespec_store(&ts, until - n);
if (sigtimedwait(&mask, NULL, &ts) != SIGCHLD)
- log_warning("Failed: sigtimedwait did not return SIGCHLD: %m");
+ if (errno != EAGAIN)
+ log_warning("Failed: sigtimedwait did not return SIGCHLD: %m");
}
finish: