rtpsrc: Always set rtcp socket address

Regardless if it's multicast or not, set the address property to match
the element address. This is the address of the interface to listen to,
which is expected to be ANY in most cases, but should be honnored even
for RTCP non-multicast case.

This also fixes an assertion if the address is not a parsable IPv4 or
IPv6 string.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1433>
This commit is contained in:
Nicolas Dufresne 2020-07-11 15:16:53 -04:00 committed by GStreamer Merge Bot
parent 82fe23f212
commit f6ac2e44bb

View file

@ -184,17 +184,9 @@ gst_rtp_src_set_property (GObject * object, guint prop_id,
break;
}
case PROP_ADDRESS:{
GInetAddress *addr;
gst_uri_set_host (self->uri, g_value_get_string (value));
g_object_set_property (G_OBJECT (self->rtp_src), "address", value);
addr = g_inet_address_new_from_string (gst_uri_get_host (self->uri));
if (g_inet_address_get_is_multicast (addr)) {
g_object_set (self->rtcp_src, "address", gst_uri_get_host (self->uri),
NULL);
}
g_object_unref (addr);
g_object_set_property (G_OBJECT (self->rtcp_src), "address", value);
break;
}
case PROP_PORT:{