summaryrefslogtreecommitdiff
path: root/toxcore
diff options
context:
space:
mode:
Diffstat (limited to 'toxcore')
-rw-r--r--toxcore/TCP_client.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/toxcore/TCP_client.c b/toxcore/TCP_client.c
index 6ead44a5..bc1b7ff4 100644
--- a/toxcore/TCP_client.c
+++ b/toxcore/TCP_client.c
@@ -451,7 +451,7 @@ static int handle_TCP_packet(TCP_Client_Connection *conn, const uint8_t *data, u
451 uint8_t con_id = data[1] - NUM_RESERVED_PORTS; 451 uint8_t con_id = data[1] - NUM_RESERVED_PORTS;
452 452
453 if (conn->connections[con_id].status != 1) 453 if (conn->connections[con_id].status != 1)
454 return -1; 454 return 0;
455 455
456 conn->connections[con_id].status = 2; 456 conn->connections[con_id].status = 2;
457 457
@@ -475,7 +475,7 @@ static int handle_TCP_packet(TCP_Client_Connection *conn, const uint8_t *data, u
475 return 0; 475 return 0;
476 476
477 if (conn->connections[con_id].status != 2) 477 if (conn->connections[con_id].status != 2)
478 return -1; 478 return 0;
479 479
480 conn->connections[con_id].status = 1; 480 conn->connections[con_id].status = 1;
481 481