History

fix crash issue for too big packet size

Licai Guo committed 12 years ago

Commit 15bd7da1 parent c7f19743 files · +11 −4Browse files

Showing the changes to codec/decoder/core/src/decoder_core.cpp (1 of 3 files). Show all

Unified · Split

codec/decoder/core/src/decoder_core.cpp+3−3
@@ -303,13 +303,13 @@ int32_t WelsInitMemory (PWelsDecoderContext pCtx) { · 302 unmodified lines
303 if (MemInitNalList (&pCtx->pAccessUnitList, MAX_NAL_UNIT_NUM_IN_AU) != 0)303 if (MemInitNalList (&pCtx->pAccessUnitList, MAX_NAL_UNIT_NUM_IN_AU) != 0)
304 return ERR_INFO_OUT_OF_MEMORY;304 return ERR_INFO_OUT_OF_MEMORY;
305 305
306 if ((pCtx->sRawData.pHead = static_cast<uint8_t*> (WelsMalloc (MAX_ACCESS_UINT_CAPACITY,306 if ((pCtx->sRawData.pHead = static_cast<uint8_t*> (WelsMalloc (MAX_ACCESS_UNIT_CAPACITY,
307 "pCtx->sRawData->pHead"))) == NULL) {307 "pCtx->sRawData->pHead"))) == NULL) {
308 return ERR_INFO_OUT_OF_MEMORY;308 return ERR_INFO_OUT_OF_MEMORY;
309 }309 }
310 pCtx->sRawData.pStartPos =310 pCtx->sRawData.pStartPos =
311 pCtx->sRawData.pCurPos = pCtx->sRawData.pHead;311 pCtx->sRawData.pCurPos = pCtx->sRawData.pHead;
312 pCtx->sRawData.pEnd = pCtx->sRawData.pHead + MAX_ACCESS_UINT_CAPACITY;312 pCtx->sRawData.pEnd = pCtx->sRawData.pHead + MAX_ACCESS_UNIT_CAPACITY;
313 313
314 pCtx->uiTargetDqId = (uint8_t) - 1;314 pCtx->uiTargetDqId = (uint8_t) - 1;
315 pCtx->bEndOfStreamFlag = false;315 pCtx->bEndOfStreamFlag = false;
@@ -1968,4 +1968,4 @@ int32_t DecodeCurrentAccessUnit (PWelsDecoderContext pCtx, uint8_t** ppDst, int3 · 1652 unmodified lines
1968 return ERR_NONE;1968 return ERR_NONE;
1969}1969}
1970 1970
1971} // namespace WelsDec1971} // namespace WelsDec

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t