gsturi: Remove unnecessary code

gst_uri_handler_set_uri() function has new_uri, location and colon
are not necessary, they can be removed.

https://bugzilla.gnome.org/show_bug.cgi?id=736877
This commit is contained in:
Ravi Kiran K N 2014-09-19 09:42:10 +05:30 committed by Luis de Bethencourt
parent eefe8be9fe
commit 7a93e6b005

View file

@ -733,7 +733,7 @@ gst_uri_handler_set_uri (GstURIHandler * handler, const gchar * uri,
{
GstURIHandlerInterface *iface;
gboolean ret;
gchar *new_uri, *protocol, *location, *colon;
gchar *protocol;
g_return_val_if_fail (GST_IS_URI_HANDLER (handler), FALSE);
g_return_val_if_fail (gst_uri_is_valid (uri), FALSE);
@ -768,15 +768,8 @@ gst_uri_handler_set_uri (GstURIHandler * handler, const gchar * uri,
}
}
colon = strstr (uri, ":");
location = g_strdup (colon);
new_uri = g_strdup_printf ("%s%s", protocol, location);
ret = iface->set_uri (handler, uri, error);
g_free (new_uri);
g_free (location);
g_free (protocol);
return ret;