[gtk+/gtk-3-18] Load settings.ini from all data dirs
- From: Matthias Clasen <matthiasc src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtk+/gtk-3-18] Load settings.ini from all data dirs
- Date: Mon, 9 Nov 2015 13:52:30 +0000 (UTC)
commit d38c29f48b3cc09ff8db7e52be967d7d046c40fb
Author: Matthias Clasen <mclasen redhat com>
Date: Sat Oct 31 18:13:29 2015 -0400
Load settings.ini from all data dirs
An error in the loading function was making us load the file from
the first data dir repeatedly, instead.
https://bugzilla.gnome.org/show_bug.cgi?id=757377
gtk/gtksettings.c | 5 ++---
1 files changed, 2 insertions(+), 3 deletions(-)
---
diff --git a/gtk/gtksettings.c b/gtk/gtksettings.c
index cc74a06..a59b6ab 100644
--- a/gtk/gtksettings.c
+++ b/gtk/gtksettings.c
@@ -290,7 +290,6 @@ gtk_settings_init (GtkSettings *settings)
guint i = 0;
gchar *path;
const gchar * const *config_dirs;
- const gchar *config_dir;
priv = gtk_settings_get_instance_private (settings);
settings->priv = priv;
@@ -340,9 +339,9 @@ gtk_settings_init (GtkSettings *settings)
g_free (path);
config_dirs = g_get_system_config_dirs ();
- for (config_dir = *config_dirs; *config_dirs != NULL; config_dirs++)
+ for (i = 0; config_dirs[i] != NULL; i++)
{
- path = g_build_filename (config_dir, "gtk-3.0", "settings.ini", NULL);
+ path = g_build_filename (config_dirs[i], "gtk-3.0", "settings.ini", NULL);
if (g_file_test (path, G_FILE_TEST_EXISTS))
gtk_settings_load_from_key_file (settings, path, GTK_SETTINGS_SOURCE_DEFAULT);
g_free (path);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]