Replace CHECK(x && y) with two separate CHECK() calls
That way, the debug printout will tell us which of x and y that was false. BUG=none Review-Url: https://codereview.webrtc.org/2988153003 Cr-Commit-Position: refs/heads/master@{#19297}
This commit is contained in:
@ -218,13 +218,15 @@ ComfortNoiseEncoder::ComfortNoiseEncoder(int fs, int interval, int quality)
|
||||
enc_reflCoefs_{0},
|
||||
enc_corrVector_{0},
|
||||
enc_seed_(7777) /* For debugging only. */ {
|
||||
RTC_CHECK(quality <= WEBRTC_CNG_MAX_LPC_ORDER && quality > 0);
|
||||
RTC_CHECK_GT(quality, 0);
|
||||
RTC_CHECK_LE(quality, WEBRTC_CNG_MAX_LPC_ORDER);
|
||||
/* Needed to get the right function pointers in SPLIB. */
|
||||
WebRtcSpl_Init();
|
||||
}
|
||||
|
||||
void ComfortNoiseEncoder::Reset(int fs, int interval, int quality) {
|
||||
RTC_CHECK(quality <= WEBRTC_CNG_MAX_LPC_ORDER && quality > 0);
|
||||
RTC_CHECK_GT(quality, 0);
|
||||
RTC_CHECK_LE(quality, WEBRTC_CNG_MAX_LPC_ORDER);
|
||||
enc_nrOfCoefs_ = quality;
|
||||
enc_sampfreq_ = fs;
|
||||
enc_interval_ = interval;
|
||||
|
||||
@ -391,7 +391,8 @@ AudioEncoderOpus::AudioEncoderOpus(
|
||||
? std::move(bitrate_smoother) : std::unique_ptr<SmoothingFilter>(
|
||||
// We choose 5sec as initial time constant due to empirical data.
|
||||
new SmoothingFilterImpl(5000))) {
|
||||
RTC_DCHECK(0 <= payload_type && payload_type <= 127);
|
||||
RTC_DCHECK_GE(payload_type, 0);
|
||||
RTC_DCHECK_LE(payload_type, 127);
|
||||
|
||||
// Sanity check of the redundant payload type field that we want to get rid
|
||||
// of. See https://bugs.chromium.org/p/webrtc/issues/detail?id=7847
|
||||
|
||||
Reference in New Issue
Block a user