Index: webrtc/modules/audio_processing/echo_control_mobile_impl.cc |
diff --git a/webrtc/modules/audio_processing/echo_control_mobile_impl.cc b/webrtc/modules/audio_processing/echo_control_mobile_impl.cc |
index a9457d96d9de21ab1712d080f530e7d3e88b0326..a00927dbb8bd01124dfcca9a47fbece0fb1b14db 100644 |
--- a/webrtc/modules/audio_processing/echo_control_mobile_impl.cc |
+++ b/webrtc/modules/audio_processing/echo_control_mobile_impl.cc |
@@ -96,7 +96,7 @@ class EchoControlMobileImpl::Canceller { |
RTC_DCHECK(state_); |
int error = WebRtcAecm_Init(state_, sample_rate_hz); |
RTC_DCHECK_EQ(AudioProcessing::kNoError, error); |
- if (external_echo_path != NULL) { |
+ if (external_echo_path != nullptr) { |
error = WebRtcAecm_InitEchoPath(state_, external_echo_path, |
echo_path_size_bytes); |
RTC_DCHECK_EQ(AudioProcessing::kNoError, error); |
@@ -114,15 +114,15 @@ EchoControlMobileImpl::EchoControlMobileImpl(rtc::CriticalSection* crit_render, |
crit_capture_(crit_capture), |
routing_mode_(kSpeakerphone), |
comfort_noise_enabled_(true), |
- external_echo_path_(NULL) { |
+ external_echo_path_(nullptr) { |
RTC_DCHECK(crit_render); |
RTC_DCHECK(crit_capture); |
} |
EchoControlMobileImpl::~EchoControlMobileImpl() { |
- if (external_echo_path_ != NULL) { |
- delete [] external_echo_path_; |
- external_echo_path_ = NULL; |
+ if (external_echo_path_ != nullptr) { |
+ delete[] external_echo_path_; |
+ external_echo_path_ = nullptr; |
} |
} |
@@ -201,9 +201,9 @@ int EchoControlMobileImpl::ProcessCaptureAudio(AudioBuffer* audio, |
// This is kind of hacked up. |
const int16_t* noisy = audio->low_pass_reference(capture); |
const int16_t* clean = audio->split_bands_const(capture)[kBand0To8kHz]; |
- if (noisy == NULL) { |
+ if (noisy == nullptr) { |
noisy = clean; |
- clean = NULL; |
+ clean = nullptr; |
} |
for (size_t render = 0; render < stream_properties_->num_reverse_channels; |
++render) { |
@@ -293,7 +293,7 @@ int EchoControlMobileImpl::SetEchoPath(const void* echo_path, |
{ |
rtc::CritScope cs_render(crit_render_); |
rtc::CritScope cs_capture(crit_capture_); |
- if (echo_path == NULL) { |
+ if (echo_path == nullptr) { |
return AudioProcessing::kNullPointerError; |
} |
if (size_bytes != echo_path_size_bytes()) { |
@@ -301,7 +301,7 @@ int EchoControlMobileImpl::SetEchoPath(const void* echo_path, |
return AudioProcessing::kBadParameterError; |
} |
- if (external_echo_path_ == NULL) { |
+ if (external_echo_path_ == nullptr) { |
external_echo_path_ = new unsigned char[size_bytes]; |
} |
memcpy(external_echo_path_, echo_path, size_bytes); |
@@ -319,7 +319,7 @@ int EchoControlMobileImpl::SetEchoPath(const void* echo_path, |
int EchoControlMobileImpl::GetEchoPath(void* echo_path, |
size_t size_bytes) const { |
rtc::CritScope cs(crit_capture_); |
- if (echo_path == NULL) { |
+ if (echo_path == nullptr) { |
return AudioProcessing::kNullPointerError; |
} |
if (size_bytes != echo_path_size_bytes()) { |