| Index: webrtc/call/rtp_stream_receiver_controller.cc
|
| diff --git a/webrtc/call/rtp_stream_receiver_controller.cc b/webrtc/call/rtp_stream_receiver_controller.cc
|
| index 123866535299f3ce8d5104241bcb1c3b3164edea..94fa83b60e6699ae3c0cb1373a4c1143af43371e 100644
|
| --- a/webrtc/call/rtp_stream_receiver_controller.cc
|
| +++ b/webrtc/call/rtp_stream_receiver_controller.cc
|
| @@ -9,6 +9,8 @@
|
| */
|
|
|
| #include "webrtc/call/rtp_stream_receiver_controller.h"
|
| +
|
| +#include "webrtc/rtc_base/logging.h"
|
| #include "webrtc/rtc_base/ptr_util.h"
|
|
|
| namespace webrtc {
|
| @@ -18,7 +20,11 @@ RtpStreamReceiverController::Receiver::Receiver(
|
| uint32_t ssrc,
|
| RtpPacketSinkInterface* sink)
|
| : controller_(controller), sink_(sink) {
|
| - controller_->AddSink(ssrc, sink_);
|
| + const bool sink_added = controller_->AddSink(ssrc, sink_);
|
| + if (!sink_added) {
|
| + LOG(LS_ERROR) << "RtpStreamReceiverController::Receiver::Receiver: Sink "
|
| + << "could not be added for SSRC=" << ssrc << ".";
|
| + }
|
| }
|
|
|
| RtpStreamReceiverController::Receiver::~Receiver() {
|
| @@ -43,7 +49,7 @@ bool RtpStreamReceiverController::OnRtpPacket(const RtpPacketReceived& packet) {
|
| return demuxer_.OnRtpPacket(packet);
|
| }
|
|
|
| -void RtpStreamReceiverController::AddSink(uint32_t ssrc,
|
| +bool RtpStreamReceiverController::AddSink(uint32_t ssrc,
|
| RtpPacketSinkInterface* sink) {
|
| rtc::CritScope cs(&lock_);
|
| return demuxer_.AddSink(ssrc, sink);
|
|
|