Commit 8991e576 authored by Thomas Vander Stichele's avatar Thomas Vander Stichele
Browse files

fixes #112711

Original commit message from CVS:
fixes #112711
parent 863a0f81
......@@ -269,7 +269,8 @@ gst_videotestsrc_getcaps (GstPad * pad, GstCaps * caps)
"height",GST_PROPS_INT_RANGE(16,4096));
}
return gst_caps_intersect(caps1,caps2);
/* ref intersection and return it */
return gst_caps_ref (gst_caps_intersect(caps1,caps2));
}
static void
......@@ -318,6 +319,12 @@ gst_videotestsrc_get (GstPad * pad)
buf = NULL;
if (videotestsrc->pool) {
buf = gst_buffer_new_from_pool (videotestsrc->pool, 0, 0);
/* if the buffer we get is too small, make our own */
if (GST_BUFFER_SIZE (buf) < newsize)
{
gst_buffer_unref (buf);
buf = NULL;
}
}
if (!buf) {
buf = gst_buffer_new ();
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment