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

Unified Diff: webrtc/p2p/base/relayport.cc

Issue 2766063005: Revert of Removing HTTPS and SOCKS proxy server code. (Closed)
Patch Set: Merge with master Created 3 years, 9 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
« no previous file with comments | « webrtc/p2p/base/portallocator.h ('k') | webrtc/p2p/client/basicportallocator.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: webrtc/p2p/base/relayport.cc
diff --git a/webrtc/p2p/base/relayport.cc b/webrtc/p2p/base/relayport.cc
index 3d56c4acb437f09fa075e8047740f69314a8af3b..2ab71dc3e4e5664bb47a04a81f5d79494d4da3c5 100644
--- a/webrtc/p2p/base/relayport.cc
+++ b/webrtc/p2p/base/relayport.cc
@@ -210,7 +210,15 @@ RelayPort::~RelayPort() {
}
void RelayPort::AddServerAddress(const ProtocolAddress& addr) {
- server_addr_.push_back(addr);
+ // Since HTTP proxies usually only allow 443,
+ // let's up the priority on PROTO_SSLTCP
+ if (addr.proto == PROTO_SSLTCP &&
+ (proxy().type == rtc::PROXY_HTTPS ||
+ proxy().type == rtc::PROXY_UNKNOWN)) {
+ server_addr_.push_front(addr);
+ } else {
+ server_addr_.push_back(addr);
+ }
}
void RelayPort::AddExternalAddress(const ProtocolAddress& addr) {
« no previous file with comments | « webrtc/p2p/base/portallocator.h ('k') | webrtc/p2p/client/basicportallocator.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698