Original commit message from CVS:
- Proxy the get_caps function slightly differently. This is potentially
dangerous as it works quite differently. My tests seem to work though and
it fixes the play-multi-file-segfault in the player.
GstPad *otherpad;
if (pad == queue->srcpad)
- otherpad = queue->sinkpad;
+ otherpad = GST_PAD_PEER (queue->sinkpad);
else
- otherpad = queue->srcpad;
+ otherpad = GST_PAD_PEER (queue->srcpad);
+
+ if (otherpad)
+ return gst_pad_get_caps (otherpad);
- return gst_pad_get_allowed_caps (otherpad);
+ return NULL;
}
static void
GstPad *otherpad;
if (pad == queue->srcpad)
- otherpad = queue->sinkpad;
+ otherpad = GST_PAD_PEER (queue->sinkpad);
else
- otherpad = queue->srcpad;
+ otherpad = GST_PAD_PEER (queue->srcpad);
+
+ if (otherpad)
+ return gst_pad_get_caps (otherpad);
- return gst_pad_get_allowed_caps (otherpad);
+ return NULL;
}
static void