safe_close(pipe_fd[1]);
if (r < 0)
- log_error("Failed to fork TTY ask password agent: %s", strerror(-r));
+ log_error_errno(r, "Failed to fork TTY ask password agent: %m");
else
/* Wait until the agent closes the fd */
- fd_wait_for_event(pipe_fd[0], POLLHUP, (usec_t) -1);
+ fd_wait_for_event(pipe_fd[0], POLLHUP, USEC_INFINITY);
safe_close(pipe_fd[0]);
/* Inform agent that we are done */
kill(agent_pid, SIGTERM);
kill(agent_pid, SIGCONT);
- wait_for_terminate(agent_pid, NULL);
+ (void) wait_for_terminate(agent_pid, NULL);
agent_pid = 0;
}