diff options
author | Matthew Barnes <mbarnes@redhat.com> | 2010-09-01 19:06:48 +0800 |
---|---|---|
committer | Matthew Barnes <mbarnes@redhat.com> | 2010-09-01 19:07:28 +0800 |
commit | f0d7a4142e8fb4ea492657aeb67c5a7bacf7af89 (patch) | |
tree | 8d65fe5a11eab80ed526776591142ebc5f49e1bd | |
parent | d724d33f0c0b892d20c09bd16ac25fa70cea73e1 (diff) | |
download | gsoc2013-evolution-f0d7a4142e8fb4ea492657aeb67c5a7bacf7af89.tar gsoc2013-evolution-f0d7a4142e8fb4ea492657aeb67c5a7bacf7af89.tar.gz gsoc2013-evolution-f0d7a4142e8fb4ea492657aeb67c5a7bacf7af89.tar.bz2 gsoc2013-evolution-f0d7a4142e8fb4ea492657aeb67c5a7bacf7af89.tar.lz gsoc2013-evolution-f0d7a4142e8fb4ea492657aeb67c5a7bacf7af89.tar.xz gsoc2013-evolution-f0d7a4142e8fb4ea492657aeb67c5a7bacf7af89.tar.zst gsoc2013-evolution-f0d7a4142e8fb4ea492657aeb67c5a7bacf7af89.zip |
Bug 628482 - e_shell_settings_install_property_for_key memory leak
-rw-r--r-- | shell/e-shell-settings.c | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/shell/e-shell-settings.c b/shell/e-shell-settings.c index 7c5cac4e53..9503f967f7 100644 --- a/shell/e-shell-settings.c +++ b/shell/e-shell-settings.c @@ -60,16 +60,19 @@ shell_settings_pspec_for_key (const gchar *property_name, entry = gconf_client_get_entry (client, gconf_key, NULL, TRUE, &error); if (error != NULL) { + g_warning ("%s", error->message); + g_error_free (error); return NULL; } schema_name = gconf_entry_get_schema_name (entry); - if (schema_name == NULL) { - return NULL; - } + g_return_val_if_fail (schema_name != NULL, NULL); schema = gconf_client_get_schema (client, schema_name, &error); if (error != NULL) { + g_warning ("%s", error->message); + gconf_entry_unref (entry); + g_error_free (error); return NULL; } @@ -157,6 +160,7 @@ shell_settings_pspec_for_key (const gchar *property_name, gconf_value_free (default_value); gconf_schema_free (schema); + gconf_entry_unref (entry); return pspec; |