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

Unified Diff: webrtc/modules/rtp_rtcp/source/rtp_payload_registry_unittest.cc

Issue 1924443002: Revert of Replace the remaining scoped_ptr with unique_ptr in webrtc/modules/ (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: Created 4 years, 8 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/modules/rtp_rtcp/source/rtp_payload_registry_unittest.cc
diff --git a/webrtc/modules/rtp_rtcp/source/rtp_payload_registry_unittest.cc b/webrtc/modules/rtp_rtcp/source/rtp_payload_registry_unittest.cc
index 5bbe97a32ce300d6d3118524fff0fd252faa2909..cbded6872d389330f958c82716ba8ddc679df721 100644
--- a/webrtc/modules/rtp_rtcp/source/rtp_payload_registry_unittest.cc
+++ b/webrtc/modules/rtp_rtcp/source/rtp_payload_registry_unittest.cc
@@ -8,12 +8,11 @@
* be found in the AUTHORS file in the root of the source tree.
*/
-#include <memory>
-
#include "webrtc/modules/rtp_rtcp/include/rtp_payload_registry.h"
#include "testing/gmock/include/gmock/gmock.h"
#include "testing/gtest/include/gtest/gtest.h"
+#include "webrtc/base/scoped_ptr.h"
#include "webrtc/modules/rtp_rtcp/include/rtp_header_parser.h"
#include "webrtc/modules/rtp_rtcp/source/byte_io.h"
#include "webrtc/modules/rtp_rtcp/source/mock/mock_rtp_payload_strategy.h"
@@ -59,7 +58,7 @@
return returned_payload_on_heap;
}
- std::unique_ptr<RTPPayloadRegistry> rtp_payload_registry_;
+ rtc::scoped_ptr<RTPPayloadRegistry> rtp_payload_registry_;
testing::NiceMock<MockRTPPayloadStrategy>* mock_payload_strategy_;
};
@@ -297,9 +296,9 @@
uint16_t original_sequence_number = 1234;
uint32_t original_ssrc = 500;
- std::unique_ptr<const uint8_t[]> packet(GenerateRtxPacket(
+ rtc::scoped_ptr<const uint8_t[]> packet(GenerateRtxPacket(
header_length, payload_length, original_sequence_number));
- std::unique_ptr<uint8_t[]> restored_packet(
+ rtc::scoped_ptr<uint8_t[]> restored_packet(
new uint8_t[header_length + payload_length]);
size_t length = original_length;
bool success = rtp_payload_registry->RestoreOriginalPacket(
@@ -313,7 +312,7 @@
EXPECT_EQ(original_length - kRtxHeaderSize, length)
<< "The restored packet should be exactly kRtxHeaderSize smaller.";
- std::unique_ptr<RtpHeaderParser> header_parser(RtpHeaderParser::Create());
+ rtc::scoped_ptr<RtpHeaderParser> header_parser(RtpHeaderParser::Create());
RTPHeader restored_header;
ASSERT_TRUE(
header_parser->Parse(restored_packet.get(), length, &restored_header));
« no previous file with comments | « webrtc/modules/rtp_rtcp/source/rtp_format_vp9_unittest.cc ('k') | webrtc/modules/rtp_rtcp/source/rtp_receiver_impl.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698