mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-01-30 19:18:31 +00:00
ext/ffmpeg/gstffmpegenc.c: Fix use of already-freed caps.
Original commit message from CVS: * ext/ffmpeg/gstffmpegenc.c: (gst_ffmpegenc_connect): Fix use of already-freed caps.
This commit is contained in:
parent
8a6c344dc7
commit
df75119488
1 changed files with 2 additions and 0 deletions
|
@ -370,8 +370,10 @@ gst_ffmpegenc_connect (GstPad *pad,
|
||||||
* function. */
|
* function. */
|
||||||
if (!gst_pad_set_explicit_caps (ffmpegenc->srcpad, icaps)) {
|
if (!gst_pad_set_explicit_caps (ffmpegenc->srcpad, icaps)) {
|
||||||
avcodec_close (ffmpegenc->context);
|
avcodec_close (ffmpegenc->context);
|
||||||
|
gst_caps_free (icaps);
|
||||||
return GST_PAD_LINK_REFUSED;
|
return GST_PAD_LINK_REFUSED;
|
||||||
}
|
}
|
||||||
|
gst_caps_free (icaps);
|
||||||
|
|
||||||
/* success! */
|
/* success! */
|
||||||
ffmpegenc->opened = TRUE;
|
ffmpegenc->opened = TRUE;
|
||||||
|
|
Loading…
Reference in a new issue