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

Unified Diff: webrtc/modules/audio_coding/acm2/rent_a_codec.cc

Issue 1677013002: Switch to using new ACM methods for encoder management (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@acm-13
Patch Set: DCHECKs 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/audio_coding/acm2/rent_a_codec.cc
diff --git a/webrtc/modules/audio_coding/acm2/rent_a_codec.cc b/webrtc/modules/audio_coding/acm2/rent_a_codec.cc
index 3bf959e901eab5a297be6256e22e0d2914668242..7f1e52030dc944f9efe244d8fd7f96eec432ebc8 100644
--- a/webrtc/modules/audio_coding/acm2/rent_a_codec.cc
+++ b/webrtc/modules/audio_coding/acm2/rent_a_codec.cc
@@ -263,7 +263,8 @@ RentACodec::StackParameters::~StackParameters() = default;
std::unique_ptr<AudioEncoder> RentACodec::RentEncoderStack(
StackParameters* param) {
- RTC_DCHECK(param->speech_encoder);
+ if (!param->speech_encoder)
+ return nullptr;
if (param->use_codec_fec) {
// Switch FEC on. On failure, remember that FEC is off.
« no previous file with comments | « webrtc/modules/audio_coding/acm2/rent_a_codec.h ('k') | webrtc/modules/audio_coding/acm2/rent_a_codec_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698