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

Unified Diff: webrtc/pc/channel.cc

Issue 1741933002: Prevent a voice channel from sending data before a renderer is set. (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: Adding a TODO and returning a const pointer. 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
« webrtc/media/engine/webrtcvoiceengine_unittest.cc ('K') | « webrtc/pc/channel.h ('k') | no next file » | 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 1d5d159d05fd786eafc6fb909fb96298d64e3c52..82affc1059d99977cdefc4f7aa018a4085522a35 100644
--- a/webrtc/pc/channel.cc
+++ b/webrtc/pc/channel.cc
@@ -1342,9 +1342,9 @@ bool VoiceChannel::Init() {
bool VoiceChannel::SetAudioSend(uint32_t ssrc,
bool enable,
const AudioOptions* options,
- AudioRenderer* renderer) {
+ AudioSource* source) {
return InvokeOnWorker(Bind(&VoiceMediaChannel::SetAudioSend, media_channel(),
- ssrc, enable, options, renderer));
+ ssrc, enable, options, source));
}
// TODO(juberti): Handle early media the right way. We should get an explicit
@@ -1462,9 +1462,8 @@ void VoiceChannel::ChangeState() {
// Send outgoing data if we're the active call, we have the remote content,
// and we have had some form of connectivity.
bool send = IsReadyToSend();
- SendFlags send_flag = send ? SEND_MICROPHONE : SEND_NOTHING;
- if (!media_channel()->SetSend(send_flag)) {
- LOG(LS_ERROR) << "Failed to SetSend " << send_flag << " on voice channel";
+ if (!media_channel()->SetSend(send)) {
+ LOG(LS_ERROR) << "Failed to SetSend " << send << " on voice channel";
the sun 2016/03/07 21:24:54 SetSend() always returns true now. This will never
Taylor Brandstetter 2016/03/08 00:00:31 Done.
}
LOG(LS_INFO) << "Changing voice state, recv=" << recv << " send=" << send;
« webrtc/media/engine/webrtcvoiceengine_unittest.cc ('K') | « webrtc/pc/channel.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698