mirror of https://git.ffmpeg.org/ffmpeg.git
lavc: free buffer_frame/pkt on avcodec_open2() failure
Fixes memory leaks in some FATE tests.
This commit is contained in:
parent
ec021d4844
commit
e9bfff1cc6
|
@ -1199,6 +1199,8 @@ FF_ENABLE_DEPRECATION_WARNINGS
|
|||
av_freep(&avctx->priv_data);
|
||||
if (avctx->internal) {
|
||||
av_frame_free(&avctx->internal->to_free);
|
||||
av_frame_free(&avctx->internal->buffer_frame);
|
||||
av_packet_free(&avctx->internal->buffer_pkt);
|
||||
av_freep(&avctx->internal->pool);
|
||||
}
|
||||
av_freep(&avctx->internal);
|
||||
|
|
Loading…
Reference in New Issue