diff options
Diffstat (limited to 'source3/lib/util_str.c')
-rw-r--r-- | source3/lib/util_str.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/source3/lib/util_str.c b/source3/lib/util_str.c index 226bf826fb..1f3aab3bce 100644 --- a/source3/lib/util_str.c +++ b/source3/lib/util_str.c @@ -2280,11 +2280,12 @@ static char *ipstr_list_add(char **ipstr_list, const struct ip_service *service) return NULL; } + print_sockaddr(addr_buf, + sizeof(addr_buf), + &service->ss); + /* attempt to convert ip to a string and append colon separator to it */ if (*ipstr_list) { - print_sockaddr(addr_buf, - sizeof(addr_buf), - &service->ss); if (service->ss.ss_family == AF_INET) { /* IPv4 */ asprintf(&new_ipstr, "%s%s%s:%d", |