From 910a317089ade0321426832dd9da77e9120446be Mon Sep 17 00:00:00 2001 From: Wonsik Kim Date: Wed, 29 Apr 2020 16:58:16 -0700 Subject: [PATCH] CCodec: don't drop work with format change Bug: 151995371 Test: atest CtsMediaTestCases -- --module-arg CtsMediaTestCases:size:small Change-Id: I335519cddf762adb39e7518f15b1cfecf1d43550 --- media/codec2/sfplugin/CCodecBufferChannel.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/media/codec2/sfplugin/CCodecBufferChannel.cpp b/media/codec2/sfplugin/CCodecBufferChannel.cpp index 6b389d58fc..ecb7ee6233 100644 --- a/media/codec2/sfplugin/CCodecBufferChannel.cpp +++ b/media/codec2/sfplugin/CCodecBufferChannel.cpp @@ -1704,8 +1704,8 @@ bool CCodecBufferChannel::handleWork( } } - if (!buffer && !flags) { - ALOGV("[%s] onWorkDone: Not reporting output buffer (%lld)", + if (!buffer && !flags && outputFormat == nullptr) { + ALOGV("[%s] onWorkDone: nothing to report from the work (%lld)", mName, work->input.ordinal.frameIndex.peekull()); return true; }