From 90e74a66e663f1776457d599cb7d5ce44785a56c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Zbigniew=20J=C4=99drzejewski-Szmek?= Date: Tue, 8 Sep 2020 11:58:29 +0200 Subject: tree-wide: define iterator inside of the macro --- src/tty-ask-password-agent/tty-ask-password-agent.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'src/tty-ask-password-agent') diff --git a/src/tty-ask-password-agent/tty-ask-password-agent.c b/src/tty-ask-password-agent/tty-ask-password-agent.c index 87779a4dd6..932f6e18b2 100644 --- a/src/tty-ask-password-agent/tty-ask-password-agent.c +++ b/src/tty-ask-password-agent/tty-ask-password-agent.c @@ -583,7 +583,6 @@ static void terminate_agents(Set *pids) { struct timespec ts; siginfo_t status = {}; sigset_t set; - Iterator i; void *p; int r, signum; @@ -591,7 +590,7 @@ static void terminate_agents(Set *pids) { * Request termination of the remaining processes as those * are not required anymore. */ - SET_FOREACH(p, pids, i) + SET_FOREACH(p, pids) (void) kill(PTR_TO_PID(p), SIGTERM); /* @@ -625,7 +624,7 @@ static void terminate_agents(Set *pids) { /* * Kill hanging processes. */ - SET_FOREACH(p, pids, i) { + SET_FOREACH(p, pids) { log_warning("Failed to terminate child %d, killing it", PTR_TO_PID(p)); (void) kill(PTR_TO_PID(p), SIGKILL); } -- cgit v1.2.1