Showing the changes to codec/decoder/core/src/decoder_core.cpp (1 of 1 file). Show all
Unified · Split
| @@ -2416,8 +2416,10 @@ bool CheckAndFinishLastPic (PWelsDecoderContext pCtx, uint8_t** ppDst, SBufferIn · 2415 unmodified lines | ||
| 2416 | 2416 | pCtx->bFrameFinish = true; //clear frame pending status here! |
| 2417 | 2417 | } else { |
| 2418 | 2418 | if (DecodeFrameConstruction (pCtx, ppDst, pDstInfo)) { |
| 2419 | − if (pCtx->sLastNalHdrExt.sNalUnitHeader.uiNalRefIdc > 0) | |
| 2419 | + if ((pCtx->sLastNalHdrExt.sNalUnitHeader.uiNalRefIdc > 0) && (pCtx->sLastNalHdrExt.uiTemporalId == 0)) | |
| 2420 | 2420 | pCtx->iErrorCode |= dsNoParamSets; |
| 2421 | + else | |
| 2422 | + pCtx->iErrorCode |= dsBitstreamError; | |
| 2421 | 2423 | pCtx->pDec = NULL; |
| 2422 | 2424 | return false; |
| 2423 | 2425 | } |