summaryrefslogtreecommitdiff
path: root/src/basic/process-util.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/basic/process-util.c')
-rw-r--r--src/basic/process-util.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/src/basic/process-util.c b/src/basic/process-util.c
index 369edce816..680900c731 100644
--- a/src/basic/process-util.c
+++ b/src/basic/process-util.c
@@ -820,13 +820,12 @@ int wait_for_terminate_with_timeout(pid_t pid, usec_t timeout) {
for (;;) {
usec_t n;
siginfo_t status = {};
- struct timespec ts;
n = now(CLOCK_MONOTONIC);
if (n >= until)
break;
- r = RET_NERRNO(sigtimedwait(&mask, NULL, timespec_store(&ts, until - n)));
+ r = RET_NERRNO(sigtimedwait(&mask, NULL, TIMESPEC_STORE(until - n)));
/* Assuming we woke due to the child exiting. */
if (waitid(P_PID, pid, &status, WEXITED|WNOHANG) == 0) {
if (status.si_pid == pid) {