Index: webrtc/modules/rtp_rtcp/test/testFec/test_packet_masks_metrics.cc |
diff --git a/webrtc/modules/rtp_rtcp/test/testFec/test_packet_masks_metrics.cc b/webrtc/modules/rtp_rtcp/test/testFec/test_packet_masks_metrics.cc |
index b7c4ef5506b1a11f67e573cfae7d8cacd3edec9a..466214c740e229d17a8a50d57803c463d47d8033 100644 |
--- a/webrtc/modules/rtp_rtcp/test/testFec/test_packet_masks_metrics.cc |
+++ b/webrtc/modules/rtp_rtcp/test/testFec/test_packet_masks_metrics.cc |
@@ -45,9 +45,8 @@ |
#include <math.h> |
-#include <memory> |
- |
#include "testing/gtest/include/gtest/gtest.h" |
+#include "webrtc/base/scoped_ptr.h" |
#include "webrtc/modules/rtp_rtcp/source/forward_error_correction_internal.h" |
#include "webrtc/modules/rtp_rtcp/test/testFec/average_residual_loss_xor_codes.h" |
#include "webrtc/test/testsupport/fileutils.h" |
@@ -192,7 +191,7 @@ |
int RecoveredMediaPackets(int num_media_packets, |
int num_fec_packets, |
uint8_t* state) { |
- std::unique_ptr<uint8_t[]> state_tmp( |
+ rtc::scoped_ptr<uint8_t[]> state_tmp( |
new uint8_t[num_media_packets + num_fec_packets]); |
memcpy(state_tmp.get(), state, num_media_packets + num_fec_packets); |
int num_recovered_packets = 0; |
@@ -386,7 +385,7 @@ |
// (which containes the code size parameters/protection length). |
void ComputeMetricsForCode(CodeType code_type, |
int code_index) { |
- std::unique_ptr<double[]> prob_weight(new double[kNumLossModels]); |
+ rtc::scoped_ptr<double[]> prob_weight(new double[kNumLossModels]); |
memset(prob_weight.get() , 0, sizeof(double) * kNumLossModels); |
MetricsFecCode metrics_code; |
SetMetricsZero(&metrics_code); |
@@ -394,7 +393,7 @@ |
int num_media_packets = code_params_[code_index].num_media_packets; |
int num_fec_packets = code_params_[code_index].num_fec_packets; |
int tot_num_packets = num_media_packets + num_fec_packets; |
- std::unique_ptr<uint8_t[]> state(new uint8_t[tot_num_packets]); |
+ rtc::scoped_ptr<uint8_t[]> state(new uint8_t[tot_num_packets]); |
memset(state.get() , 0, tot_num_packets); |
int num_loss_configurations = static_cast<int>(pow(2.0f, tot_num_packets)); |