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

Unified Diff: webrtc/pc/channel.cc

Issue 1783263002: Replace scoped_ptr with unique_ptr in webrtc/pc/ (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: Created 4 years, 9 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 | « webrtc/pc/channel.h ('k') | webrtc/pc/channel_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: webrtc/pc/channel.cc
diff --git a/webrtc/pc/channel.cc b/webrtc/pc/channel.cc
index e978d7d4b0e2bdcf8f7c084fc16572dd5fd5b1fb..e5658092c87f33734640cabcb0f035d202c1be3e 100644
--- a/webrtc/pc/channel.cc
+++ b/webrtc/pc/channel.cc
@@ -29,11 +29,11 @@ namespace cricket {
using rtc::Bind;
namespace {
-// See comment below for why we need to use a pointer to a scoped_ptr.
+// See comment below for why we need to use a pointer to a unique_ptr.
bool SetRawAudioSink_w(VoiceMediaChannel* channel,
uint32_t ssrc,
- rtc::scoped_ptr<webrtc::AudioSinkInterface>* sink) {
- channel->SetRawAudioSink(ssrc, rtc::ScopedToUnique(std::move(*sink)));
+ std::unique_ptr<webrtc::AudioSinkInterface>* sink) {
+ channel->SetRawAudioSink(ssrc, std::move(*sink));
return true;
}
} // namespace
@@ -1377,8 +1377,8 @@ bool VoiceChannel::SetOutputVolume(uint32_t ssrc, double volume) {
void VoiceChannel::SetRawAudioSink(
uint32_t ssrc,
- rtc::scoped_ptr<webrtc::AudioSinkInterface> sink) {
- // We need to work around Bind's lack of support for scoped_ptr and ownership
+ std::unique_ptr<webrtc::AudioSinkInterface> sink) {
+ // We need to work around Bind's lack of support for unique_ptr and ownership
// passing. So we invoke to our own little routine that gets a pointer to
// our local variable. This is OK since we're synchronously invoking.
InvokeOnWorker(Bind(&SetRawAudioSink_w, media_channel(), ssrc, &sink));
« no previous file with comments | « webrtc/pc/channel.h ('k') | webrtc/pc/channel_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698