summaryrefslogtreecommitdiff
path: root/src/core/execute.c
diff options
context:
space:
mode:
authorLennart Poettering <lennart@poettering.net>2015-09-11 18:15:08 +0200
committerLennart Poettering <lennart@poettering.net>2015-09-11 18:31:49 +0200
commitc7cc737fce8e5ba8438c1613756b48a0c2ecbb0f (patch)
tree249b8dc464c0da3f2987fead296c9f0f0a370fad /src/core/execute.c
parent54eb2300ae07d28922a18a9d14dc597850535e9c (diff)
execute: fix return type from write()
Diffstat (limited to 'src/core/execute.c')
-rw-r--r--src/core/execute.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/core/execute.c b/src/core/execute.c
index 8773d9cdfb..3c308e3e3e 100644
--- a/src/core/execute.c
+++ b/src/core/execute.c
@@ -1169,9 +1169,11 @@ static void do_idle_pipe_dance(int idle_pipe[4]) {
r = fd_wait_for_event(idle_pipe[0], POLLHUP, IDLE_TIMEOUT_USEC);
if (idle_pipe[3] >= 0 && r == 0 /* timeout */) {
+ ssize_t n;
+
/* Signal systemd that we are bored and want to continue. */
- r = write(idle_pipe[3], "x", 1);
- if (r > 0)
+ n = write(idle_pipe[3], "x", 1);
+ if (n > 0)
/* Wait for systemd to react to the signal above. */
fd_wait_for_event(idle_pipe[0], POLLHUP, IDLE_TIMEOUT2_USEC);
}