From f3822e7828adf1a955a0eab808daaa84cdcb6952 Mon Sep 17 00:00:00 2001 From: ChenHengming Date: Tue, 7 Jun 2016 02:57:35 +0000 Subject: [PATCH] [h264d]: remove extra flush on deinit [h265d]: prevent possible multiple set eos git-svn-id: https://10.10.10.66:8443/svn/MediaProcessPlatform/trunk/mpp@882 6e48237b-75ef-9749-8fc9-41990f28c85a --- mpp/codec/dec/h264/h264d_api.c | 1 - mpp/codec/dec/h265/h265d_parser.c | 1 + 2 files changed, 1 insertion(+), 1 deletion(-) diff --git a/mpp/codec/dec/h264/h264d_api.c b/mpp/codec/dec/h264/h264d_api.c index f1791e89..4a2eac0b 100644 --- a/mpp/codec/dec/h264/h264d_api.c +++ b/mpp/codec/dec/h264/h264d_api.c @@ -446,7 +446,6 @@ MPP_RET h264d_deinit(void *decoder) INP_CHECK(ret, !decoder); FunctionIn(p_Dec->logctx.parr[RUN_PARSE]); - h264d_flush(decoder); free_input_ctx(p_Dec->p_Inp); MPP_FREE(p_Dec->p_Inp); free_cur_ctx(p_Dec->p_Cur); diff --git a/mpp/codec/dec/h265/h265d_parser.c b/mpp/codec/dec/h265/h265d_parser.c index f60b5c82..5b0bd97a 100644 --- a/mpp/codec/dec/h265/h265d_parser.c +++ b/mpp/codec/dec/h265/h265d_parser.c @@ -1981,6 +1981,7 @@ MPP_RET h265d_flush(void *ctx) frame = &s->DPB[s->output_frame_idx]; if ((frame->slot_index < 0xff) && s->eos) { mpp_buf_slot_set_prop(s->slots, frame->slot_index, SLOT_EOS, &eos); + frame->slot_index = 0xff; } else { if (s->notify_cb.callBack != NULL && s->eos) { s->notify_cb.callBack(s->notify_cb.opaque, NULL);