projects
/
oweals
/
tinc.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
| inline |
side by side
Prevent freeing a NULL pointer when a hostname is unresolvable.
[oweals/tinc.git]
/
src
/
net_socket.c
diff --git
a/src/net_socket.c
b/src/net_socket.c
index bf5130d6a7dbc8f86662b96126dcba9671ba44b1..753229b4fd01e90887e45118b0965697ab28c65c 100644
(file)
--- a/
src/net_socket.c
+++ b/
src/net_socket.c
@@
-300,7
+300,8
@@
begin:
}
if(!c->outgoing->aip) {
- freeaddrinfo(c->outgoing->ai);
+ if(c->outgoing->ai)
+ freeaddrinfo(c->outgoing->ai);
c->outgoing->ai = NULL;
goto begin;
}