From b4ec98dbec67e7ec1e3363cae7a14f2f12b4e5d5 Mon Sep 17 00:00:00 2001 From: Matias De Lellis Date: Mon, 1 Dec 2014 14:56:05 -0600 Subject: [PATCH] GtkPlacesSidebar: Fix Home and Desktop on Windows. We were concatenating "file://" to the result of g_get_user_special_dir() to build a URI, but this is not enough on Windows. Use g_filename_to_uri() instead. See https://bugzilla.gnome.org/show_bug.cgi?id=739453 --- gtk/gtkplacessidebar.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gtk/gtkplacessidebar.c b/gtk/gtkplacessidebar.c index c811dc132c..7b61b426cb 100644 --- a/gtk/gtkplacessidebar.c +++ b/gtk/gtkplacessidebar.c @@ -690,7 +690,7 @@ get_home_directory_uri (void) if (!home) return NULL; - return g_strconcat ("file://", home, NULL); + return g_filename_to_uri (home, NULL, NULL); } static gchar * @@ -706,7 +706,7 @@ get_desktop_directory_uri (void) if (path_is_home_dir (name)) return NULL; - return g_strconcat ("file://", name, NULL); + return g_filename_to_uri (name, NULL, NULL); } static gboolean