From f5b079e688fd0e644e2526aaf048b60f2f3a90fa Mon Sep 17 00:00:00 2001 From: Tor Lillqvist Date: Fri, 25 Nov 2005 14:56:22 +0000 Subject: Use g_filename_from_uri() instead of just stripping off the "file://" 2005-11-25 Tor Lillqvist * gui/widgets/eab-gui-util.c (eab_load_error_dialog): Use g_filename_from_uri() instead of just stripping off the "file://" prefix for Win32 portability. svn path=/trunk/; revision=30671 --- addressbook/gui/widgets/eab-gui-util.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'addressbook/gui/widgets/eab-gui-util.c') diff --git a/addressbook/gui/widgets/eab-gui-util.c b/addressbook/gui/widgets/eab-gui-util.c index aeb259d3e8..7d210fcdbe 100644 --- a/addressbook/gui/widgets/eab-gui-util.c +++ b/addressbook/gui/widgets/eab-gui-util.c @@ -97,10 +97,11 @@ eab_load_error_dialog (GtkWidget *parent, ESource *source, EBookStatus status) } else if (!strncmp (uri, "file:", 5)) { - const char *path = uri+7; /* file:// */ + char *path = g_filename_from_uri (uri, NULL, NULL); label = g_strdup_printf ( _("We were unable to open this addressbook. Please check that the " "path %s exists and that you have permission to access it."), path); + g_free (path); label_string = label; } else if (!strncmp (uri, "ldap:", 5)) { -- cgit