glupload: Release glupload buffer when caps are changed

https://bugzilla.gnome.org/show_bug.cgi?id=748371
This commit is contained in:
Matthieu Bouron 2015-04-23 16:47:40 +02:00 committed by Matthew Waters
parent e5d62b073b
commit 8f740fb484

View file

@ -194,8 +194,10 @@ _gst_gl_upload_element_set_caps (GstBaseTransform * bt, GstCaps * in_caps,
gst_caps_replace (&upload->in_caps, in_caps); gst_caps_replace (&upload->in_caps, in_caps);
gst_caps_replace (&upload->out_caps, out_caps); gst_caps_replace (&upload->out_caps, out_caps);
if (upload->upload) if (upload->upload) {
gst_gl_upload_release_buffer (upload->upload);
return gst_gl_upload_set_caps (upload->upload, in_caps, out_caps); return gst_gl_upload_set_caps (upload->upload, in_caps, out_caps);
}
return TRUE; return TRUE;
} }