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

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

Issue 2025573002: Use continual gathering to restore backup connections (Closed) Base URL: https://chromium.googlesource.com/external/webrtc@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
Index: webrtc/p2p/base/p2ptransportchannel.h
diff --git a/webrtc/p2p/base/p2ptransportchannel.h b/webrtc/p2p/base/p2ptransportchannel.h
index ada3ecfb8bb2deeb6bc5d9120eb1647d7cd1a1da..6ee85f024eb8e4ceb57b87618254a64d13e5d150 100644
--- a/webrtc/p2p/base/p2ptransportchannel.h
+++ b/webrtc/p2p/base/p2ptransportchannel.h
@@ -234,6 +234,8 @@ class P2PTransportChannel : public TransportChannelImpl,
void OnPortReady(PortAllocatorSession *session, PortInterface* port);
void OnCandidatesReady(PortAllocatorSession *session,
const std::vector<Candidate>& candidates);
+ void OnCandidatesRemoved(PortAllocatorSession* session,
+ const std::vector<Candidate>& candidates);
void OnCandidatesAllocationDone(PortAllocatorSession* session);
void OnUnknownAddress(PortInterface* port,
const rtc::SocketAddress& addr,
@@ -241,8 +243,12 @@ class P2PTransportChannel : public TransportChannelImpl,
IceMessage* stun_msg,
const std::string& remote_username,
bool port_muxed);
+
+ // When a port is destroyed or closed, remove it from our list of ports to
+ // use for connection attempts.
void OnPortDestroyed(PortInterface* port);
- void OnPortNetworkInactive(PortInterface* port);
+ void OnPortClosed(PortInterface* port);
+ bool RemovePort(PortInterface* port);
void OnRoleConflict(PortInterface* port);
void OnConnectionStateChange(Connection* connection);
@@ -257,6 +263,7 @@ class P2PTransportChannel : public TransportChannelImpl,
void OnMessage(rtc::Message* pmsg) override;
void OnSort();
void OnCheckAndPing();
+ void OnRegatherOnFailedNetworks();
void PruneConnections();
Connection* best_nominated_connection() const;
@@ -332,6 +339,7 @@ class P2PTransportChannel : public TransportChannelImpl,
TransportChannelState state_ = TransportChannelState::STATE_INIT;
IceConfig config_;
int last_sent_packet_id_ = -1; // -1 indicates no packet was sent before.
+ std::vector<Candidate> candidates_to_remove_;
RTC_DISALLOW_COPY_AND_ASSIGN(P2PTransportChannel);
};

Powered by Google App Engine
This is Rietveld 408576698