[gnome-software/wip/ubuntu-xenial] trivial: Build broken - Use GFile correctly
- From: William Hua <williamhua src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-software/wip/ubuntu-xenial] trivial: Build broken - Use GFile correctly
- Date: Tue, 26 Apr 2016 07:25:35 +0000 (UTC)
commit 73a6fb4027ab9e6b0bbe88df2fa035c3e1f55215
Author: Robert Ancell <robert ancell canonical com>
Date: Mon Apr 25 11:35:34 2016 +0200
trivial: Build broken - Use GFile correctly
src/plugins/gs-plugin-packagekit-refresh.c | 12 ++++++------
1 files changed, 6 insertions(+), 6 deletions(-)
---
diff --git a/src/plugins/gs-plugin-packagekit-refresh.c b/src/plugins/gs-plugin-packagekit-refresh.c
index 216b26d..afb2f78 100644
--- a/src/plugins/gs-plugin-packagekit-refresh.c
+++ b/src/plugins/gs-plugin-packagekit-refresh.c
@@ -309,7 +309,7 @@ gs_plugin_file_to_app (GsPlugin *plugin,
data.ptask = NULL;
/* get details */
- files = g_strsplit (filename, "\t", -1);
+ files = g_strsplit (g_file_get_path (file), "\t", -1);
pk_client_set_cache_age (PK_CLIENT (plugin->priv->task), G_MAXUINT);
results = pk_client_get_details_local (PK_CLIENT (plugin->priv->task),
files,
@@ -325,7 +325,7 @@ gs_plugin_file_to_app (GsPlugin *plugin,
g_set_error (error,
GS_PLUGIN_ERROR,
GS_PLUGIN_ERROR_FAILED,
- "no details for %s", filename);
+ "no details for %s", g_file_get_path (file));
return FALSE;
}
if (array->len > 1) {
@@ -333,7 +333,7 @@ gs_plugin_file_to_app (GsPlugin *plugin,
GS_PLUGIN_ERROR,
GS_PLUGIN_ERROR_FAILED,
"too many details [%i] for %s",
- array->len, filename);
+ array->len, g_file_get_path (file));
return FALSE;
}
@@ -342,7 +342,7 @@ gs_plugin_file_to_app (GsPlugin *plugin,
app = gs_app_new (NULL);
package_id = pk_details_get_package_id (item);
split = pk_package_id_split (package_id);
- basename = g_path_get_basename (filename);
+ basename = g_path_get_basename (g_file_get_path (file));
gs_app_set_management_plugin (app, "PackageKit");
gs_app_set_kind (app, AS_APP_KIND_GENERIC);
gs_app_set_state (app, AS_APP_STATE_AVAILABLE_LOCAL);
@@ -352,7 +352,7 @@ gs_plugin_file_to_app (GsPlugin *plugin,
else
gs_app_set_name (app, GS_APP_QUALITY_LOWEST, split[PK_PACKAGE_ID_NAME]);
gs_app_set_version (app, split[PK_PACKAGE_ID_VERSION]);
- gs_app_set_metadata (app, "PackageKit::local-filename", filename);
+ gs_app_set_metadata (app, "PackageKit::local-filename", g_file_get_path (file));
gs_app_set_origin (app, basename);
gs_app_add_source (app, split[PK_PACKAGE_ID_NAME]);
gs_app_add_source_id (app, package_id);
@@ -366,7 +366,7 @@ gs_plugin_file_to_app (GsPlugin *plugin,
/* look for a desktop file so we can use a valid application id */
if (!gs_plugin_packagekit_refresh_guess_app_id (plugin,
app,
- filename,
+ g_file_get_path (file),
cancellable,
error))
return FALSE;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]