diff options
author | Ryan Lortie <desrt@desrt.ca> | 2010-12-21 12:53:44 -0500 |
---|---|---|
committer | Ryan Lortie <desrt@desrt.ca> | 2010-12-21 12:53:44 -0500 |
commit | 388974f02f3267e118e2facdb32631331460aa04 (patch) | |
tree | 30c22459a690eddf6054f5b4faf99af12ef009bb /service/dconf-writer.c | |
parent | e28fe589f4013b50770ee595f2d09e84c383f8c1 (diff) | |
download | dconf-388974f02f3267e118e2facdb32631331460aa04.tar.gz |
Fix DBus introspection enumeration
It should also work for people who have usernames other than 'desrt'
Closes #634229.
Diffstat (limited to 'service/dconf-writer.c')
-rw-r--r-- | service/dconf-writer.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/service/dconf-writer.c b/service/dconf-writer.c index 3cf58f5..3b98efd 100644 --- a/service/dconf-writer.c +++ b/service/dconf-writer.c @@ -56,11 +56,13 @@ gchar ** dconf_writer_list_existing (void) { GPtrArray *array; + gchar *path; GDir *dir; + path = g_build_filename (g_get_user_config_dir (), "dconf", NULL); array = g_ptr_array_new (); - if ((dir = g_dir_open ("/home/desrt/.config/dconf", 0, NULL))) + if ((dir = g_dir_open (path, 0, NULL))) { const gchar *name; @@ -70,6 +72,7 @@ dconf_writer_list_existing (void) } g_ptr_array_add (array, NULL); + g_free (path); return (gchar **) g_ptr_array_free (array, FALSE); } |