From 572fb60392f2bdbea0b738ab9cc4eca2aefe6585 Mon Sep 17 00:00:00 2001 From: irungentoo Date: Sat, 9 Nov 2013 22:29:16 -0500 Subject: [PATCH] Optimized data sending slightly more. --- toxcore/Lossless_UDP.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/toxcore/Lossless_UDP.c b/toxcore/Lossless_UDP.c index ce1779ec..8b9beb63 100644 --- a/toxcore/Lossless_UDP.c +++ b/toxcore/Lossless_UDP.c @@ -860,8 +860,8 @@ static void adjust_datasendspeed(Connection *connection, uint32_t req_packets) return; } - if (req_packets <= (connection->data_rate / connection->SYNC_rate) / 5 || req_packets <= 10) { - connection->data_rate += (connection->data_rate / 8) + 1; + if (req_packets <= (connection->data_rate / connection->SYNC_rate) / 4 || req_packets <= 10) { + connection->data_rate += (connection->data_rate / 4) + 1; if (connection->data_rate > connection->sendbuffer_length * connection->SYNC_rate) connection->data_rate = connection->sendbuffer_length * connection->SYNC_rate;