mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-11-27 04:01:08 +00:00
Revert "avviddec: Fix memory leaks and assertions in error cases if we can't allocate a frame"
This reverts commit 47647e1cac
.
Breaks playback when direct rendering is disabled.
The reason is that we set the opaque vaue to NULL and then try to use the NULL
value when we decoded a frame.
This commit is contained in:
parent
4fc452344a
commit
76b8b8c67f
1 changed files with 2 additions and 7 deletions
|
@ -485,7 +485,7 @@ static int
|
|||
gst_ffmpegviddec_get_buffer (AVCodecContext * context, AVFrame * picture)
|
||||
{
|
||||
GstVideoCodecFrame *frame;
|
||||
GstFFMpegVidDecVideoFrame *dframe = NULL;
|
||||
GstFFMpegVidDecVideoFrame *dframe;
|
||||
GstFFMpegVidDec *ffmpegdec;
|
||||
gint c;
|
||||
GstVideoInfo *info;
|
||||
|
@ -583,10 +583,6 @@ invalid_frame:
|
|||
}
|
||||
fallback:
|
||||
{
|
||||
if (dframe)
|
||||
gst_ffmpegviddec_video_frame_free (dframe);
|
||||
picture->opaque = NULL;
|
||||
|
||||
return avcodec_default_get_buffer (context, picture);
|
||||
}
|
||||
duplicate_frame:
|
||||
|
@ -673,7 +669,6 @@ gst_ffmpegviddec_release_buffer (AVCodecContext * context, AVFrame * picture)
|
|||
/* we remove the opaque data now */
|
||||
picture->opaque = NULL;
|
||||
|
||||
if (frame)
|
||||
gst_ffmpegviddec_video_frame_free (frame);
|
||||
|
||||
/* zero out the reference in ffmpeg */
|
||||
|
|
Loading…
Reference in a new issue