From db6145f055f197de70d0c4793025eef0a3b1eee9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?K=C3=A1ri=20Tristan=20Helgason?= Date: Tue, 13 Feb 2018 13:58:10 +0100 Subject: [PATCH] Fix bug in reporting decode errors in VideoToolbox MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The reference back to the decoder class in the decode callback was null. Due to the amazing properties of ObjC this led to the setError call to silently fail. Bug: webrtc:8600 Change-Id: I3f70fbe4c9d533c8612d0bc7bc40813252e492fd Reviewed-on: https://webrtc-review.googlesource.com/52460 Reviewed-by: Peter Hanspers Commit-Queue: Kári Helgason Cr-Commit-Position: refs/heads/master@{#22021} --- sdk/objc/Framework/Classes/VideoToolbox/RTCVideoDecoderH264.mm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sdk/objc/Framework/Classes/VideoToolbox/RTCVideoDecoderH264.mm b/sdk/objc/Framework/Classes/VideoToolbox/RTCVideoDecoderH264.mm index 2f4b6bd72c..e7ce739f50 100644 --- a/sdk/objc/Framework/Classes/VideoToolbox/RTCVideoDecoderH264.mm +++ b/sdk/objc/Framework/Classes/VideoToolbox/RTCVideoDecoderH264.mm @@ -236,7 +236,7 @@ void decompressionOutputCallback(void *decoderRef, pixelFormat = nullptr; } VTDecompressionOutputCallbackRecord record = { - decompressionOutputCallback, nullptr, + decompressionOutputCallback, (__bridge void *)self, }; OSStatus status = VTDecompressionSessionCreate( nullptr, _videoFormat, nullptr, attributes, &record, &_decompressionSession);