From 5b4330b2cac60b817ff94730e187e4ea87cd8597 Mon Sep 17 00:00:00 2001 From: Vincent Untz Date: Mon, 31 Oct 2011 16:00:08 +0100 Subject: Revert d7917514549f48297bc0032a7e2b54bfb17f7495 and clarify comment https://bugzilla.gnome.org/show_bug.cgi?id=662991 --- gconf/gconf-database.c | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/gconf/gconf-database.c b/gconf/gconf-database.c index 91fc6120..1bebc6bb 100644 --- a/gconf/gconf-database.c +++ b/gconf/gconf-database.c @@ -797,14 +797,15 @@ gconf_database_set_sources (GConfDatabase *db, { if (db->sources != NULL) { - /* this function should only be used when creating the db with the corba - * backend */ #ifdef HAVE_CORBA - gconf_sources_clear_cache(db->sources); - gconf_sources_free(db->sources); -#else + /* in the corba backend, this function should only be used when creating + * the db; so assert when it was already created earlier (ie, when the + * sources are already set) */ g_assert_not_reached (); #endif + + gconf_sources_clear_cache(db->sources); + gconf_sources_free(db->sources); } db->sources = sources; -- cgit v1.2.1