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

Unified Diff: webrtc/p2p/base/p2ptransportchannel.h

Issue 2053043003: Update ICE role on all ports, not just ones used for new connections. (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: Created 4 years, 6 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 | « no previous file | webrtc/p2p/base/p2ptransportchannel.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: webrtc/p2p/base/p2ptransportchannel.h
diff --git a/webrtc/p2p/base/p2ptransportchannel.h b/webrtc/p2p/base/p2ptransportchannel.h
index ada3ecfb8bb2deeb6bc5d9120eb1647d7cd1a1da..e44e5344f496e4a9a247ebc69a0d2430b4a1ff07 100644
--- a/webrtc/p2p/base/p2ptransportchannel.h
+++ b/webrtc/p2p/base/p2ptransportchannel.h
@@ -119,8 +119,8 @@ class P2PTransportChannel : public TransportChannelImpl,
void set_incoming_only(bool value) { incoming_only_ = value; }
// Note: This is only for testing purpose.
- // |ports_| should not be changed from outside.
- const std::vector<PortInterface*>& ports() { return ports_; }
+ // |active_ports_| should not be changed from outside.
+ const std::vector<PortInterface*>& ports() { return active_ports_; }
IceMode remote_ice_mode() const { return remote_ice_mode_; }
@@ -297,7 +297,13 @@ class P2PTransportChannel : public TransportChannelImpl,
bool incoming_only_;
int error_;
std::vector<std::unique_ptr<PortAllocatorSession>> allocator_sessions_;
- std::vector<PortInterface *> ports_;
+ // |active_ports_| contains ports that are used to form new connections when
+ // new remote candidates are added.
+ std::vector<PortInterface*> active_ports_;
+ // |inactive_ports_| contains ports that aren't being used to form new
+ // connections, but that aren't yet destroyed. They may have existing
+ // connections, and they still fire signals such as SignalUnknownAddress.
+ std::vector<PortInterface*> inactive_ports_;
pthatcher1 2016/06/15 22:13:20 For names, how about ports_ and removed_ports_wait
Taylor Brandstetter 2016/06/16 00:53:33 I think removed_ports_ is sufficiently unambiguous
// |connections_| is a sorted list with the first one always be the
// |best_connection_| when it's not nullptr. The combination of
« no previous file with comments | « no previous file | webrtc/p2p/base/p2ptransportchannel.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698