Commit 3e9d2361 authored by Rusty Russell's avatar Rusty Russell

net: fix leak in test.

Signed-off-by: default avatarRusty Russell <rusty@rustcorp.com.au>
parent 4f09cf20
......@@ -117,6 +117,7 @@ int main(void)
close(fd);
for (i = 0; i < num_fds; i++)
close(fds[i]);
freeaddrinfo(addr);
/* Simple UDP test. */
addr = net_server_lookup(TEST_PORT, AF_UNSPEC, SOCK_DGRAM);
......@@ -155,6 +156,7 @@ int main(void)
if (addr->ai_next)
ipv6_only = true;
#endif
freeaddrinfo(addr);
if (ipv6_only) {
int j;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment