History

move the rc free to the correct condition to avoid access to invalid memory

sijchen committed 10 years ago

Commit b76a79c1 parent 025500d1 file · +1 −1Browse files

Showing the changes to codec/encoder/core/src/encoder_ext.cpp (1 of 1 file). Show all

Unified · Split

codec/encoder/core/src/encoder_ext.cpp+1−1
@@ -2256,9 +2256,9 @@ void FreeMemorySvc (sWelsEncCtx** ppCtx) { · 2255 unmodified lines
2256 pCtx->pVaa = NULL;2256 pCtx->pVaa = NULL;
2257 }2257 }
2258 2258
2259 WelsRcFreeMemory (pCtx);
2260 // rate control module memory free2259 // rate control module memory free
2261 if (NULL != pCtx->pWelsSvcRc) {2260 if (NULL != pCtx->pWelsSvcRc) {
2261 WelsRcFreeMemory (pCtx);
2262 pMa->WelsFree (pCtx->pWelsSvcRc, "pWelsSvcRc");2262 pMa->WelsFree (pCtx->pWelsSvcRc, "pWelsSvcRc");
2263 pCtx->pWelsSvcRc = NULL;2263 pCtx->pWelsSvcRc = NULL;
2264 }2264 }

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