projects
/
oweals
/
tinc.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
4a1740e
)
Prevent freeing a NULL pointer when a hostname is unresolvable.
author
Guus Sliepen
<guus@tinc-vpn.org>
Tue, 18 Nov 2008 15:11:27 +0000
(15:11 +0000)
committer
Guus Sliepen
<guus@tinc-vpn.org>
Tue, 18 Nov 2008 15:11:27 +0000
(15:11 +0000)
src/net_socket.c
patch
|
blob
|
history
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;
}