Including the file path in the error string. Fixes #309624.

svn path=/trunk/; revision=29683
This commit is contained in:
Sushma Rai
2005-07-08 08:06:49 +00:00
parent 9cdf0d0f6e
commit e1fc2d427b
2 changed files with 12 additions and 4 deletions

View File

@ -1,3 +1,8 @@
2005-07-08 Frederic Crozat <fcrozat@mandriva.com>
* gui/widgets/eab-gui-util.c (eab_load_error_dialog): Including the
file path in the error string. Fixes #309624
2005-07-07 Frederic Crozat <fcrozat@mandriva.com>
* gui/component/addressbook-component.c: (ensure_sources):

View File

@ -80,7 +80,7 @@ eab_error_dialog (const char *msg, EBookStatus status)
void
eab_load_error_dialog (GtkWidget *parent, ESource *source, EBookStatus status)
{
char *label_string, *uri;
char *label_string, *label = NULL, *uri;
g_return_if_fail (source != NULL);
@ -94,9 +94,11 @@ eab_load_error_dialog (GtkWidget *parent, ESource *source, EBookStatus status)
}
else if (!strncmp (uri, "file:", 5)) {
label_string =
const char *path = uri+7; /* file:// */
label = g_strdup_printf (
_("We were unable to open this addressbook. Please check that the "
"path exists and that you have permission to access it.");
"path %s exists and that you have permission to access it."), path);
label_string = label;
}
else if (!strncmp (uri, "ldap:", 5)) {
/* special case for ldap: contact folders so we can tell the user about openldap */
@ -120,7 +122,8 @@ eab_load_error_dialog (GtkWidget *parent, ESource *source, EBookStatus status)
}
e_error_run ((GtkWindow *) parent, "addressbook:load-error", label_string, NULL);
g_free (label);
g_free (uri);
}