ffdec: Make metadata writable before setting caps

In case we haven't created the output buffer, we should make
metadata writable before setting caps on it.
Fixes check unit tests.
This commit is contained in:
Thiago Santos 2010-03-11 10:13:46 -03:00
parent c300a0a9f2
commit b234d0b308

View file

@ -2255,6 +2255,7 @@ gst_ffmpegdec_frame (GstFFMpegDec * ffmpegdec,
ffmpegdec->discont = FALSE; ffmpegdec->discont = FALSE;
} }
/* set caps */ /* set caps */
outbuf = gst_buffer_make_metadata_writable (outbuf);
gst_buffer_set_caps (outbuf, GST_PAD_CAPS (ffmpegdec->srcpad)); gst_buffer_set_caps (outbuf, GST_PAD_CAPS (ffmpegdec->srcpad));
if (ffmpegdec->segment.rate > 0.0) { if (ffmpegdec->segment.rate > 0.0) {