summaryrefslogtreecommitdiff
path: root/toxcore/Lossless_UDP.c
diff options
context:
space:
mode:
Diffstat (limited to 'toxcore/Lossless_UDP.c')
-rw-r--r--toxcore/Lossless_UDP.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/toxcore/Lossless_UDP.c b/toxcore/Lossless_UDP.c
index e291340d..ce1779ec 100644
--- a/toxcore/Lossless_UDP.c
+++ b/toxcore/Lossless_UDP.c
@@ -832,8 +832,7 @@ static int handle_SYNC2(Lossless_UDP *ludp, int connection_id, uint8_t counter,
832{ 832{
833 Connection *connection = &tox_array_get(&ludp->connections, connection_id, Connection); 833 Connection *connection = &tox_array_get(&ludp->connections, connection_id, Connection);
834 834
835 if (recv_packetnum == connection->orecv_packetnum) { 835 if (recv_packetnum == connection->orecv_packetnum && sent_packetnum == connection->osent_packetnum) {
836 /* && sent_packetnum == connection->osent_packetnum) */
837 connection->status = LUDP_ESTABLISHED; 836 connection->status = LUDP_ESTABLISHED;
838 connection->recv_counter = counter; 837 connection->recv_counter = counter;
839 ++connection->send_counter; 838 ++connection->send_counter;