mirror of
https://github.com/irungentoo/toxcore.git
synced 2024-03-22 13:30:51 +08:00
When getting disconnected from good relay, try to reconnect.
This commit is contained in:
parent
fb9fc81a35
commit
cb815f7584
|
@ -2107,6 +2107,8 @@ static void clear_disconnected_tcp(Net_Crypto *c)
|
||||||
continue;
|
continue;
|
||||||
|
|
||||||
c->tcp_connections[i] = NULL;
|
c->tcp_connections[i] = NULL;
|
||||||
|
/* Try reconnecting to relay on disconnect. */
|
||||||
|
add_tcp_relay(c, tcp_con->ip_port, tcp_con->public_key);
|
||||||
kill_TCP_connection(tcp_con);
|
kill_TCP_connection(tcp_con);
|
||||||
|
|
||||||
for (j = 0; j < c->crypto_connections_length; ++j) {
|
for (j = 0; j < c->crypto_connections_length; ++j) {
|
||||||
|
|
Loading…
Reference in New Issue
Block a user