From 1a0456a06bf7d0046d656a700a99e7ab016acbae Mon Sep 17 00:00:00 2001 From: winlin Date: Fri, 9 Apr 2021 22:44:56 +0800 Subject: [PATCH] Threads: TODO: Sort the packets, to avoid NACK --- trunk/src/app/srs_app_hybrid.cpp | 6 ------ trunk/src/app/srs_app_threads.cpp | 1 + 2 files changed, 1 insertion(+), 6 deletions(-) diff --git a/trunk/src/app/srs_app_hybrid.cpp b/trunk/src/app/srs_app_hybrid.cpp index c168a5cabf..fdbf5a8320 100644 --- a/trunk/src/app/srs_app_hybrid.cpp +++ b/trunk/src/app/srs_app_hybrid.cpp @@ -183,12 +183,6 @@ srs_error_t SrsHybridServer::initialize() // A monitor to check the clock wall deviation, per clock tick. timer_->subscribe(20 * SRS_UTIME_MILLISECONDS, clock_monitor_); - // Consume the async UDP/SRTP packets. - if ((err = _srs_thread_pool->consume()) != srs_success) { - return srs_error_wrap(err, "srtp"); - } - } - vector::iterator it; for (it = servers.begin(); it != servers.end(); ++it) { ISrsHybridServer* server = *it; diff --git a/trunk/src/app/srs_app_threads.cpp b/trunk/src/app/srs_app_threads.cpp index 261c0c91e9..769da53e21 100644 --- a/trunk/src/app/srs_app_threads.cpp +++ b/trunk/src/app/srs_app_threads.cpp @@ -1181,6 +1181,7 @@ srs_error_t SrsAsyncSRTPManager::consume(SrsThreadEntry* entry, int* nn_consumed // How many messages to run a yield. uint32_t nn_msgs_for_yield = 0; + // TODO: FIXME: Sort the packets, to avoid NACK. vector flying_cooked_packets; entry->cooked_packets_->swap(flying_cooked_packets);