Bug 1234571 - unregister encoded-frame callback when releasing codec databases. r=pkerr, a=al
authorRandell Jesup <rjesup@jesup.org>
Mon, 04 Jan 2016 12:27:51 -0500
changeset 304168 0b7ba87369066dc4401dac3a8ab81ca0cb366993
parent 304167 692ee3b8ba0ab463fda9876c8b4a04f04830c891
child 304169 ab7fb0565f5aa7d89b1c7fc72d9064c4a592626e
push id5451
push userrjesup@wgate.com
push dateMon, 04 Jan 2016 17:28:33 +0000
treeherdermozilla-beta@0b7ba8736906 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewerspkerr, al
bugs1234571
milestone44.0
Bug 1234571 - unregister encoded-frame callback when releasing codec databases. r=pkerr, a=al
media/webrtc/trunk/webrtc/modules/video_coding/main/source/generic_encoder.cc
--- a/media/webrtc/trunk/webrtc/modules/video_coding/main/source/generic_encoder.cc
+++ b/media/webrtc/trunk/webrtc/modules/video_coding/main/source/generic_encoder.cc
@@ -82,16 +82,17 @@ VCMGenericEncoder::VCMGenericEncoder(Vid
 VCMGenericEncoder::~VCMGenericEncoder()
 {
 }
 
 int32_t VCMGenericEncoder::Release()
 {
     _bitRate = 0;
     _frameRate = 0;
+    _encoder.RegisterEncodeCompleteCallback(NULL);
     _VCMencodedFrameCallback = NULL;
     return _encoder.Release();
 }
 
 int32_t
 VCMGenericEncoder::InitEncode(const VideoCodec* settings,
                               int32_t numberOfCores,
                               uint32_t maxPayloadSize)