Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(202)

Unified Diff: webrtc/base/proxy_unittest.cc

Issue 2828223002: Delete method MessageQueue::set_socketserver (Closed)
Patch Set: Fix memory leak in SSLAdapterTestBase. Created 3 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: webrtc/base/proxy_unittest.cc
diff --git a/webrtc/base/proxy_unittest.cc b/webrtc/base/proxy_unittest.cc
index b72d228ea0c644f00088001fd2b8938f135103de..e6abd8117993c35718c6bba486988728da8fa7c8 100644
--- a/webrtc/base/proxy_unittest.cc
+++ b/webrtc/base/proxy_unittest.cc
@@ -31,19 +31,19 @@ static const SocketAddress kBogusProxyIntAddr("1.2.3.4", 999);
// Sets up a virtual socket server and HTTPS/SOCKS5 proxy servers.
class ProxyTest : public testing::Test {
public:
- ProxyTest() : ss_(new rtc::VirtualSocketServer(nullptr)) {
- Thread::Current()->set_socketserver(ss_.get());
+ ProxyTest() : ss_(new rtc::VirtualSocketServer(nullptr)), thread_(ss_.get()) {
socks_.reset(new rtc::SocksProxyServer(
ss_.get(), kSocksProxyIntAddr, ss_.get(), kSocksProxyExtAddr));
https_.reset(new rtc::HttpListenServer());
https_->Listen(kHttpsProxyIntAddr);
}
- ~ProxyTest() { Thread::Current()->set_socketserver(nullptr); }
+ ~ProxyTest() {}
rtc::SocketServer* ss() { return ss_.get(); }
private:
std::unique_ptr<rtc::SocketServer> ss_;
+ rtc::AutoSocketServerThread thread_;
std::unique_ptr<rtc::SocksProxyServer> socks_;
// TODO: Make this a real HTTPS proxy server.
std::unique_ptr<rtc::HttpListenServer> https_;

Powered by Google App Engine
This is Rietveld 408576698