diff options
author | Rodney Dawes <dobey@novell.com> | 2006-08-21 18:11:53 +0000 |
---|---|---|
committer | Rodney Dawes <dobey@src.gnome.org> | 2006-08-21 18:11:53 +0000 |
commit | 0630f59b94298028c8e0610f5752e9e275f3222c (patch) | |
tree | 29272e732dc1affa5b31d838970694605b15ad64 /libbackground | |
parent | d737308522f4017462aed5fa06e09135ddfa3513 (diff) | |
download | gnome-control-center-0630f59b94298028c8e0610f5752e9e275f3222c.tar.gz |
Revert previous leak fix from Kjartan Maraas as it seems to cause crashesNAUTILUS_2_15_92_1
2006-08-21 Rodney Dawes <dobey@novell.com>
* preferences.c (bg_preferences_load): Revert previous leak fix from
Kjartan Maraas as it seems to cause crashes in nautilus
see bug #352279
Diffstat (limited to 'libbackground')
-rw-r--r-- | libbackground/ChangeLog | 7 | ||||
-rw-r--r-- | libbackground/preferences.c | 11 |
2 files changed, 11 insertions, 7 deletions
diff --git a/libbackground/ChangeLog b/libbackground/ChangeLog index f882b1eb0..0698f431a 100644 --- a/libbackground/ChangeLog +++ b/libbackground/ChangeLog @@ -1,3 +1,10 @@ +2006-08-21 Rodney Dawes <dobey@novell.com> + + * preferences.c (bg_preferences_load): Revert previous leak fix from + Kjartan Maraas as it seems to cause crashes in nautilus + + see bug #352279 + 2006-08-21 Kjartan Maraas <kmaraas@gnome.org> * preferences.c: (bg_preferences_load): Don't leak gconf strings. diff --git a/libbackground/preferences.c b/libbackground/preferences.c index 01c08b7e6..84eda13c9 100644 --- a/libbackground/preferences.c +++ b/libbackground/preferences.c @@ -237,7 +237,7 @@ bg_preferences_load (BGPreferences *prefs) { GConfClient *client; GError *error = NULL; - char *tmp, *shading_type, *picture_options; + char *tmp; g_return_if_fail (prefs != NULL); g_return_if_fail (IS_BG_PREFERENCES (prefs)); @@ -272,17 +272,14 @@ bg_preferences_load (BGPreferences *prefs) if (prefs->opacity >= 100 || prefs->opacity < 0) prefs->adjust_opacity = FALSE; - shading_type = gconf_client_get_string (client, BG_PREFERENCES_COLOR_SHADING_TYPE, &error); - prefs->orientation = read_orientation_from_string (shading_type); - g_free (shading_type); + prefs->orientation = read_orientation_from_string (gconf_client_get_string (client, BG_PREFERENCES_COLOR_SHADING_TYPE, &error)); if (prefs->orientation == ORIENTATION_SOLID) prefs->gradient_enabled = FALSE; else prefs->gradient_enabled = TRUE; - picture_options = gconf_client_get_string (client, BG_PREFERENCES_PICTURE_OPTIONS, &error); - prefs->wallpaper_type = read_wptype_from_string (picture_options); - g_free (picture_options); + prefs->wallpaper_type = read_wptype_from_string (gconf_client_get_string (client, BG_PREFERENCES_PICTURE_OPTIONS, &error)); + if (prefs->wallpaper_type == WPTYPE_UNSET) { prefs->wallpaper_enabled = FALSE; prefs->wallpaper_type = WPTYPE_CENTERED; |