rtpssrcdemux: Don't cross the internal links

We had the wrong condition to check for the internal links, so RTP and RTCP
pads got crossed!
This commit is contained in:
Olivier Crête 2013-04-02 21:53:10 -04:00
parent 078ff16abe
commit f4c3aef13a

View file

@ -852,10 +852,12 @@ src_pad_compare_func (gconstpointer a, gconstpointer b)
{
GstPad *pad = GST_PAD (g_value_get_object (a));
const gchar *prefix = g_value_get_string (b);
gint res = 1;
gint res;
/* 0 means equal means we accept the pad, accepted if there is a name
* and it starts with the prefix */
GST_OBJECT_LOCK (pad);
res = !GST_PAD_NAME (pad) || g_str_has_prefix (GST_PAD_NAME (pad), prefix);
res = !GST_PAD_NAME (pad) || !g_str_has_prefix (GST_PAD_NAME (pad), prefix);
GST_OBJECT_UNLOCK (pad);
return res;