| Index: webrtc/test/vcm_capturer.cc
|
| diff --git a/webrtc/test/vcm_capturer.cc b/webrtc/test/vcm_capturer.cc
|
| index 0a82236c9880487968c147938ecca7c8b83f26f9..792b97ff0883f7157a9f11f9cff622a9885b23b3 100644
|
| --- a/webrtc/test/vcm_capturer.cc
|
| +++ b/webrtc/test/vcm_capturer.cc
|
| @@ -79,17 +79,13 @@ void VcmCapturer::Stop() {
|
| }
|
|
|
| void VcmCapturer::Destroy() {
|
| - if (vcm_ == NULL) {
|
| + if (!vcm_)
|
| return;
|
| - }
|
|
|
| vcm_->StopCapture();
|
| vcm_->DeRegisterCaptureDataCallback();
|
| - vcm_->Release();
|
| -
|
| - // TODO(pbos): How do I destroy the VideoCaptureModule? This still leaves
|
| - // non-freed memory.
|
| - vcm_ = NULL;
|
| + // Release reference to VCM.
|
| + vcm_ = nullptr;
|
| }
|
|
|
| VcmCapturer::~VcmCapturer() { Destroy(); }
|
|
|