From e27f3dea8293884701283a54f90f8a429ea99505 Mon Sep 17 00:00:00 2001 From: Tomas Gunnarsson Date: Sat, 21 Nov 2020 15:20:33 +0100 Subject: [PATCH] Remove dependency on MessageHandlerAutoCleanup from BasicPortAllocatorSession and AllocationSequence All Post() calls are made to the network thread which the class already clears up explicitly. 'AutoCleanup' scans all thread instances, which is not needed for this class. Bug: webrtc:11988 Change-Id: Ieefbdc87683dc62b6156c5df72e87d404242170f Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/194339 Reviewed-by: Harald Alvestrand Commit-Queue: Tommi Cr-Commit-Position: refs/heads/master@{#32662} --- p2p/client/basic_port_allocator.h | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/p2p/client/basic_port_allocator.h b/p2p/client/basic_port_allocator.h index 26b181807a..b27016a1dc 100644 --- a/p2p/client/basic_port_allocator.h +++ b/p2p/client/basic_port_allocator.h @@ -106,9 +106,8 @@ enum class SessionState { // process will be started. }; -class RTC_EXPORT BasicPortAllocatorSession - : public PortAllocatorSession, - public rtc::MessageHandlerAutoCleanup { +class RTC_EXPORT BasicPortAllocatorSession : public PortAllocatorSession, + public rtc::MessageHandler { public: BasicPortAllocatorSession(BasicPortAllocator* allocator, const std::string& content_name, @@ -324,7 +323,7 @@ class TurnPort; // Performs the allocation of ports, in a sequenced (timed) manner, for a given // network and IP address. -class AllocationSequence : public rtc::MessageHandlerAutoCleanup, +class AllocationSequence : public rtc::MessageHandler, public sigslot::has_slots<> { public: enum State {