lavc/videotoolbox: fix failure to decode PAFF
Signed-off-by: Aman Gupta <aman@tmm1.net>
This commit is contained in:
parent
d64183ea5d
commit
4c0798578c
@ -326,11 +326,8 @@ static int videotoolbox_set_frame(AVCodecContext *avctx, AVFrame *frame)
|
|||||||
|
|
||||||
CVPixelBufferRef *ref = (CVPixelBufferRef *)frame->buf[0]->data;
|
CVPixelBufferRef *ref = (CVPixelBufferRef *)frame->buf[0]->data;
|
||||||
|
|
||||||
if (*ref) {
|
if (*ref)
|
||||||
av_log(avctx, AV_LOG_ERROR, "videotoolbox: frame already set?\n");
|
CVPixelBufferRelease(*ref);
|
||||||
av_frame_unref(frame);
|
|
||||||
return AVERROR_EXTERNAL;
|
|
||||||
}
|
|
||||||
|
|
||||||
*ref = vtctx->frame;
|
*ref = vtctx->frame;
|
||||||
vtctx->frame = NULL;
|
vtctx->frame = NULL;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user