Ensures that arrival is past send time in SimulatedNetwork.
Bug: webrtc:8415 Change-Id: I2797c7dfb3e7b9622a12c2d1e35462e0c686fa8e Reviewed-on: https://webrtc-review.googlesource.com/76101 Commit-Queue: Sebastian Jansson <srte@webrtc.org> Reviewed-by: Niels Moller <nisse@webrtc.org> Cr-Commit-Position: refs/heads/master@{#23228}
This commit is contained in:
parent
30bbbe8e79
commit
e6c0964572
@ -308,10 +308,10 @@ std::vector<PacketDeliveryInfo> SimulatedNetwork::DequeueDeliverablePackets(
|
||||
bursting_ = false;
|
||||
}
|
||||
|
||||
int64_t arrival_time_jitter_us =
|
||||
random_.Gaussian(config.queue_delay_ms,
|
||||
config.delay_standard_deviation_ms) *
|
||||
1000;
|
||||
int64_t arrival_time_jitter_us = std::max(
|
||||
random_.Gaussian(config.queue_delay_ms * 1000,
|
||||
config.delay_standard_deviation_ms * 1000),
|
||||
0.0);
|
||||
|
||||
// If reordering is not allowed then adjust arrival_time_jitter
|
||||
// to make sure all packets are sent in order.
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user