rtspconnection: Make sure to set a sensible default port for the GSocketConnection

Otherwise it will connect to port 0 if no port is given in the URI.

https://bugzilla.gnome.org/show_bug.cgi?id=701798
This commit is contained in:
Sebastian Dröge 2013-06-10 15:31:38 +02:00
parent 15375861b5
commit 567be29db2

View file

@ -647,10 +647,11 @@ gst_rtsp_connection_connect (GstRTSPConnection * conn, GTimeVal * timeout)
uri = g_strdup_printf ("http://%s:%d%s%s%s", url->host, url_port,
url->abspath, url->query ? "?" : "", url->query ? url->query : "");
} else {
uri = gst_rtsp_url_get_request_uri (conn->url);
uri = gst_rtsp_url_get_request_uri (url);
}
connection = g_socket_client_connect_to_uri (conn->client,
uri, 0, conn->cancellable, &error);
uri, url_port, conn->cancellable, &error);
if (connection == NULL)
goto connect_failed;