[Xfce4-commits] <midori:master> Show error on failure to read global config file
Christian Dywan
noreply at xfce.org
Sun Feb 13 18:36:02 CET 2011
Updating branch refs/heads/master
to 75a1d90233ed7084c1bc0a69f33339729484915b (commit)
from 5cdbf5e8141d131273609e4ec3f0776d29bcf1f1 (commit)
commit 75a1d90233ed7084c1bc0a69f33339729484915b
Author: Christian Dywan <christian at twotoasts.de>
Date: Sun Feb 13 17:53:25 2011 +0100
Show error on failure to read global config file
midori/main.c | 9 ++++++++-
1 files changed, 8 insertions(+), 1 deletions(-)
diff --git a/midori/main.c b/midori/main.c
index 4344756..2bea2c0 100644
--- a/midori/main.c
+++ b/midori/main.c
@@ -86,9 +86,16 @@ settings_and_accels_new (const gchar* config,
{
if (error->code == G_FILE_ERROR_NOENT)
{
+ GError* inner_error = NULL;
katze_assign (config_file, sokoke_find_config_filename (NULL, "config"));
g_key_file_load_from_file (key_file, config_file,
- G_KEY_FILE_KEEP_COMMENTS, NULL);
+ G_KEY_FILE_KEEP_COMMENTS, &inner_error);
+ if (inner_error != NULL)
+ {
+ printf (_("The configuration couldn't be loaded: %s\n"),
+ inner_error->message);
+ g_error_free (inner_error);
+ }
}
else
printf (_("The configuration couldn't be loaded: %s\n"),
More information about the Xfce4-commits
mailing list