[glade] Fix two memory leaks discovered with valgrind
- From: Corentin Noël <corentinnoel src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [glade] Fix two memory leaks discovered with valgrind
- Date: Tue, 18 Jun 2019 09:51:38 +0000 (UTC)
commit c5f717445460237d131a3a2d40285697e4560ac6
Author: Corentin Noël <corentin noel collabora com>
Date: Tue Jun 18 11:51:11 2019 +0200
Fix two memory leaks discovered with valgrind
gladeui/glade-builtins.c | 2 +-
gladeui/glade-widget-adaptor.c | 1 +
2 files changed, 2 insertions(+), 1 deletion(-)
---
diff --git a/gladeui/glade-builtins.c b/gladeui/glade-builtins.c
index 74721dd7..cdc98ac6 100644
--- a/gladeui/glade-builtins.c
+++ b/gladeui/glade-builtins.c
@@ -244,7 +244,7 @@ G_GNUC_END_IGNORE_DEPRECATIONS
g_slist_free (gsi_list_list);
stock_prefixs_done = TRUE;
- g_slist_free (stock_list);
+ g_slist_free_full (stock_list, g_free);
return values;
}
diff --git a/gladeui/glade-widget-adaptor.c b/gladeui/glade-widget-adaptor.c
index 992e7959..dfc29d5a 100644
--- a/gladeui/glade-widget-adaptor.c
+++ b/gladeui/glade-widget-adaptor.c
@@ -2586,6 +2586,7 @@ generate_type (const char *name, const char *parent_name)
retval = g_type_register_static (parent_type,
(new_name) ? new_name : name, type_info, 0);
+ g_free (type_info);
g_free (new_name);
return retval;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]