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

Unified Diff: webrtc/base/virtualsocketserver.h

Issue 2261523004: Signal to remove remote candidates if ports are pruned. (Closed) Base URL: https://chromium.googlesource.com/external/webrtc@master
Patch Set: . Created 4 years, 3 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/base/virtualsocketserver.cc » ('j') | webrtc/p2p/client/basicportallocator.h » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: webrtc/base/virtualsocketserver.h
diff --git a/webrtc/base/virtualsocketserver.h b/webrtc/base/virtualsocketserver.h
index 565222bfd2453357f6c22204446b21a92b5df93d..c81fceca87fbc0c932abdf62d016f910860ceb62 100644
--- a/webrtc/base/virtualsocketserver.h
+++ b/webrtc/base/virtualsocketserver.h
@@ -79,8 +79,15 @@ class VirtualSocketServer : public SocketServer, public sigslot::has_slots<> {
}
// If the (transit) delay parameters are modified, this method should be
- // called to recompute the new distribution.
+ // called to recompute the new distribution for the transit delay.
+ // If |delay_dist_ipv6_| is set, that will be used for the delay distribution
+ // of IPv6 sockets.
void UpdateDelayDistribution();
+ // Computes a new delay distribution for IPv6 sockets using the current
+ // delay parameters. If this was not called to create a delay distribution
+ // for IPv6 sockets, IPv6 sockets use the same delay distribution as
+ // |delay_dist_| set by UpdateDelayDistribution().
+ void UpdateDelayDistributionForIPv6();
// Controls the (uniform) probability that any sent packet is dropped. This
// is separate from calculations to drop based on queue size.
@@ -195,7 +202,7 @@ class VirtualSocketServer : public SocketServer, public sigslot::has_slots<> {
uint32_t SendDelay(uint32_t size);
// Returns a random transit delay chosen from the appropriate distribution.
- uint32_t GetRandomTransitDelay();
+ uint32_t GetRandomTransitDelay(Socket* socket);
// Basic operations on functions. Those that return a function also take
// ownership of the function given (and hence, may modify or delete it).
@@ -260,7 +267,9 @@ class VirtualSocketServer : public SocketServer, public sigslot::has_slots<> {
uint32_t delay_mean_;
uint32_t delay_stddev_;
uint32_t delay_samples_;
- Function* delay_dist_;
+ std::unique_ptr<Function> delay_dist_;
+ std::unique_ptr<Function> delay_dist_ipv6_;
+
CriticalSection delay_crit_;
double drop_prob_;
« no previous file with comments | « no previous file | webrtc/base/virtualsocketserver.cc » ('j') | webrtc/p2p/client/basicportallocator.h » ('J')

Powered by Google App Engine
This is Rietveld 408576698