projects
/
tinc
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
296bf09
)
Update "now" after connect() when making outgoing connections.
author
Guus Sliepen
<guus@tinc-vpn.org>
Sun, 1 Nov 2015 20:07:56 +0000
(21:07 +0100)
committer
Guus Sliepen
<guus@tinc-vpn.org>
Sun, 1 Nov 2015 20:11:00 +0000
(21:11 +0100)
It could be that address resolution takes a long time, don't let that
count against a connection. This is especially important when using a
nameserver from the VPN.
src/net_socket.c
patch
|
blob
|
history
diff --git
a/src/net_socket.c
b/src/net_socket.c
index
cb27106
..
c167c2f
100644
(file)
--- a/
src/net_socket.c
+++ b/
src/net_socket.c
@@
-457,8
+457,11
@@
begin:
freeaddrinfo(proxyai);
}
+ now = time(NULL);
+
if(result == -1) {
if(sockinprogress(sockerrno)) {
+ c->last_ping_time = now;
c->status.connecting = true;
return;
}