diff options
author | Sebastian Dröge <sebastian@centricular.com> | 2015-06-27 20:25:18 +0200 |
---|---|---|
committer | Sebastian Dröge <sebastian@centricular.com> | 2015-06-28 12:41:55 +0200 |
commit | 3d9816ce7f43ebafb40aedc0b643160e2b6a0973 (patch) | |
tree | a08dda020a90006ebdf756c7080c547c263ca39e /ext/libav/gstavviddec.c | |
parent | 982f5262d44ac42c5a2f0ed07446875424900a76 (diff) | |
download | gst-libav-3d9816ce7f43ebafb40aedc0b643160e2b6a0973.tar.gz |
avviddec: Free frame before the codec is freed
Who knows, maybe freeing the frame calls cleanup inside the codec.
Diffstat (limited to 'ext/libav/gstavviddec.c')
-rw-r--r-- | ext/libav/gstavviddec.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/ext/libav/gstavviddec.c b/ext/libav/gstavviddec.c index 79533d5..22184f8 100644 --- a/ext/libav/gstavviddec.c +++ b/ext/libav/gstavviddec.c @@ -277,14 +277,14 @@ gst_ffmpegviddec_finalize (GObject * object) { GstFFMpegVidDec *ffmpegdec = (GstFFMpegVidDec *) object; + av_frame_free (&ffmpegdec->picture); + if (ffmpegdec->context != NULL) { gst_ffmpeg_avcodec_close (ffmpegdec->context); av_free (ffmpegdec->context); ffmpegdec->context = NULL; } - av_frame_free (&ffmpegdec->picture); - G_OBJECT_CLASS (parent_class)->finalize (object); } |