audio_processing: Create now returns a pointer to the object
Affects
* NS
* AGC
* AEC
BUG=441
TESTED=locally on Linux and trybots
R=kwiberg@webrtc.org
Review URL: https://codereview.webrtc.org/1175903002.
Cr-Commit-Position: refs/heads/master@{#9411}
diff --git a/webrtc/modules/audio_processing/gain_control_impl.cc b/webrtc/modules/audio_processing/gain_control_impl.cc
index 5f301c1..398cf5c 100644
--- a/webrtc/modules/audio_processing/gain_control_impl.cc
+++ b/webrtc/modules/audio_processing/gain_control_impl.cc
@@ -301,14 +301,7 @@
}
void* GainControlImpl::CreateHandle() const {
- Handle* handle = NULL;
- if (WebRtcAgc_Create(&handle) != apm_->kNoError) {
- handle = NULL;
- } else {
- assert(handle != NULL);
- }
-
- return handle;
+ return WebRtcAgc_Create();
}
void GainControlImpl::DestroyHandle(void* handle) const {