Use free_known_addresses() to free memory allocated by get_known_addresses().
authorGuus Sliepen <guus@tinc-vpn.org>
Tue, 7 Mar 2017 18:19:19 +0000 (19:19 +0100)
committerGuus Sliepen <guus@tinc-vpn.org>
Tue, 7 Mar 2017 18:19:19 +0000 (19:19 +0100)
We know what struct addrinfo looks like, but the standard says nothing
about how it is allocated. So we cannot trust freeaddrinfo() to work
correctly on the struct addrinfo list we allocated ourselves in
get_known_addresses(). To make a distinction by allocations from the
latter and from str2addrinfo(), we keep two pointers (*ai and *kai) in
struct outgoing, and use the freeing function that is appropriate for
each.


No differences found