summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
author0xAX <0xAX@users.noreply.github.com>2016-07-02 18:17:26 +0300
committerLennart Poettering <lennart@poettering.net>2016-07-02 08:17:26 -0700
commit3a1707fff139e957b915e392ac3b5a293c8dc17b (patch)
tree791daed004f514623d8e06c45e800a3dfaabb52f /src
parent563a69f480180378ac109a4125b565ce4f394979 (diff)
sd-resolve: use close_many() (#3643)
Diffstat (limited to 'src')
-rw-r--r--src/libsystemd/sd-resolve/sd-resolve.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/src/libsystemd/sd-resolve/sd-resolve.c b/src/libsystemd/sd-resolve/sd-resolve.c
index d8303e2e69..60aa55de3b 100644
--- a/src/libsystemd/sd-resolve/sd-resolve.c
+++ b/src/libsystemd/sd-resolve/sd-resolve.c
@@ -585,9 +585,7 @@ static void resolve_free(sd_resolve *resolve) {
(void) pthread_join(resolve->workers[i], NULL);
/* Close all communication channels */
- for (i = 0; i < _FD_MAX; i++)
- safe_close(resolve->fds[i]);
-
+ close_many(resolve->fds, _FD_MAX);
free(resolve);
}