| Index: webrtc/modules/video_coding/codecs/test/packet_manipulator.cc
|
| diff --git a/webrtc/modules/video_coding/codecs/test/packet_manipulator.cc b/webrtc/modules/video_coding/codecs/test/packet_manipulator.cc
|
| index 36ba0e8272d5132e50a2e84b82dd32d5dcd173f7..b554b4e9aec50307a7305959af7a5253d8f78d85 100644
|
| --- a/webrtc/modules/video_coding/codecs/test/packet_manipulator.cc
|
| +++ b/webrtc/modules/video_coding/codecs/test/packet_manipulator.cc
|
| @@ -57,7 +57,7 @@ int PacketManipulatorImpl::ManipulatePackets(
|
| active_burst_packets_--;
|
| nbr_packets_dropped++;
|
| } else if (RandomUniform() < config_.packet_loss_probability ||
|
| - packet_loss_has_occurred) {
|
| + packet_loss_has_occurred) {
|
| packet_loss_has_occurred = true;
|
| nbr_packets_dropped++;
|
| if (config_.packet_loss_mode == kBurst) {
|
| @@ -91,9 +91,9 @@ inline double PacketManipulatorImpl::RandomUniform() {
|
| // get the same behavior as long as we're using a fixed initial seed.
|
| critsect_->Enter();
|
| srand(random_seed_);
|
| - random_seed_ = rand();
|
| + random_seed_ = rand(); // NOLINT (rand_r instead of rand)
|
| critsect_->Leave();
|
| - return (random_seed_ + 1.0)/(RAND_MAX + 1.0);
|
| + return (random_seed_ + 1.0) / (RAND_MAX + 1.0);
|
| }
|
|
|
| const char* PacketLossModeToStr(PacketLossMode e) {
|
| @@ -109,4 +109,4 @@ const char* PacketLossModeToStr(PacketLossMode e) {
|
| }
|
|
|
| } // namespace test
|
| -} // namespace webrtcc
|
| +} // namespace webrtc
|
|
|