mirror of
https://github.com/systemd/systemd
synced 2024-09-30 05:15:19 +00:00
core/socket: use FOREACH_ARRAY at one more place
This commit is contained in:
parent
64c34eb8d3
commit
42e9967baf
|
@ -272,12 +272,10 @@ static int socket_add_default_dependencies(Socket *s) {
|
|||
}
|
||||
|
||||
static bool socket_has_exec(Socket *s) {
|
||||
unsigned i;
|
||||
|
||||
assert(s);
|
||||
|
||||
for (i = 0; i < _SOCKET_EXEC_COMMAND_MAX; i++)
|
||||
if (s->exec_command[i])
|
||||
FOREACH_ARRAY(i, s->exec_command, _SOCKET_EXEC_COMMAND_MAX)
|
||||
if (*i)
|
||||
return true;
|
||||
|
||||
return false;
|
||||
|
|
Loading…
Reference in a new issue