From: Thibault Saunier Date: Thu, 16 Jan 2014 14:25:06 +0000 (+0100) Subject: uri-asset: Let a chance for user to change URI if the set one is not readable X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=f76000d7504545515d30d5cbf42ba415d2e14040;p=platform%2Fupstream%2Fgst-editing-services.git uri-asset: Let a chance for user to change URI if the set one is not readable It sounds like the most logical thing to do in that case. https://bugzilla.gnome.org/show_bug.cgi?id=721111 --- diff --git a/ges/ges-project.c b/ges/ges-project.c index 47ce90d..5c95ca8 100644 --- a/ges/ges-project.c +++ b/ges/ges-project.c @@ -461,8 +461,9 @@ ges_project_try_updating_id (GESProject * project, GESAsset * asset, id = ges_asset_get_id (asset); GST_DEBUG_OBJECT (project, "Try to proxy %s", id); if (ges_asset_request_id_update (asset, &new_id, error) == FALSE) { - GST_DEBUG_OBJECT (project, "Type: %s can not be proxied for id: %s", - g_type_name (G_OBJECT_TYPE (asset)), id); + GST_DEBUG_OBJECT (project, "Type: %s can not be proxied for id: %s " + "and error: %s", g_type_name (G_OBJECT_TYPE (asset)), id, + error->message); _send_error_loading_asset (project, asset, error); return NULL; diff --git a/ges/ges-uri-asset.c b/ges/ges-uri-asset.c index 40c4270..8d42199 100644 --- a/ges/ges-uri-asset.c +++ b/ges/ges-uri-asset.c @@ -128,7 +128,8 @@ static gboolean _request_id_update (GESAsset * self, gchar ** proposed_new_id, GError * error) { if (error->domain == GST_RESOURCE_ERROR && - error->code == GST_RESOURCE_ERROR_NOT_FOUND) { + (error->code == GST_RESOURCE_ERROR_NOT_FOUND || + error->code == GST_RESOURCE_ERROR_OPEN_READ)) { const gchar *uri = ges_asset_get_id (self); GFile *parent, *file = g_file_new_for_uri (uri);