Showing the changes to codec/decoder/core/src/cabac_decoder.cpp (1 of 2 files). Show all
Unified · Split
| @@ -273,7 +273,10 @@ int32_t DecodeExpBypassCabac (PWelsCabacDecEngine pDecEngine, int32_t iCount, ui · 272 unmodified lines | |||
| 273 | iSymTmp += (1 << iCount); | 273 | iSymTmp += (1 << iCount); |
| 274 | ++iCount; | 274 | ++iCount; |
| 275 | } | 275 | } |
| 276 | } while (uiCode != 0); | 276 | } while (uiCode != 0 && iCount != 31); |
| 277 | if (iCount == 31) { | ||
| 278 | return ERR_CABAC_UNEXPECTED_VALUE; | ||
| 279 | } | ||
| 277 | 280 | ||
| 278 | while (iCount--) { | 281 | while (iCount--) { |
| 279 | WELS_READ_VERIFY (DecodeBypassCabac (pDecEngine, uiCode)); | 282 | WELS_READ_VERIFY (DecodeBypassCabac (pDecEngine, uiCode)); |