[mpp]: Fix output slot index assertion failure while get parse error

Change-Id: I06a9897bad7edbcd96b171faaecdab38a08d46eb
Signed-off-by: Chen Jinsen <kevin.chen@rock-chips.com>
This commit is contained in:
Chen Jinsen
2019-11-07 11:57:23 +08:00
committed by Herman Chen
parent c774c8befd
commit fdc8ef19cb
2 changed files with 6 additions and 2 deletions

View File

@@ -644,7 +644,9 @@ MPP_RET h264d_callback(void *decoder, void *errinfo)
RK_U32 *p_regs = ctx->regs;
HalDecTask *task_dec = (HalDecTask *)ctx->task;
mpp_buf_slot_get_prop(p_Dec->frame_slots, task_dec->output, SLOT_FRAME_PTR, &mframe);
if (task_dec->output >= 0)
mpp_buf_slot_get_prop(p_Dec->frame_slots, task_dec->output, SLOT_FRAME_PTR, &mframe);
if (mframe) {
RK_U32 task_err = task_dec->flags.parse_err || task_dec->flags.ref_err;
if (ctx->hard_err || task_err) {