From 390f94bfd54995106c53d8fd0bea67ce9dce8176 Mon Sep 17 00:00:00 2001 From: irungentoo Date: Wed, 22 Apr 2015 09:32:36 -0400 Subject: [PATCH] Fixed possible bug. --- toxcore/net_crypto.c | 1 + 1 file changed, 1 insertion(+) diff --git a/toxcore/net_crypto.c b/toxcore/net_crypto.c index 8827e593..b6b1050a 100644 --- a/toxcore/net_crypto.c +++ b/toxcore/net_crypto.c @@ -1565,6 +1565,7 @@ int accept_crypto_connection(Net_Crypto *c, New_Connection *n_c) pthread_mutex_lock(&c->tcp_mutex); kill_tcp_connection_to(c->tcp_c, conn->connection_number_tcp); pthread_mutex_unlock(&c->tcp_mutex); + conn->status = CRYPTO_CONN_NO_CONNECTION; return -1; }