diff options
author | Vincent Untz <vuntz@gnome.org> | 2006-03-25 08:59:28 +0000 |
---|---|---|
committer | Vincent Untz <vuntz@src.gnome.org> | 2006-03-25 08:59:28 +0000 |
commit | e5fdc2d75d3fec722c167065b3fd1b7254cab60d (patch) | |
tree | c4ae80e0179f0f344443cec94de57821d195b3d7 | |
parent | ed6caaf9219bbac2c631202d3796189f1b53788b (diff) | |
download | libwnck-e5fdc2d75d3fec722c167065b3fd1b7254cab60d.tar.gz |
fix leaks fill the structure with lots of nice 0. Patch by Dan Winship
2006-03-25 Vincent Untz <vuntz@gnome.org>
* libwnck/tasklist.c: (wnck_task_finalize): fix leaks
* libwnck/xutils.c: (_wnck_icon_cache_new): fill the structure with
lots of nice 0.
Patch by Dan Winship <danw@novell.com>
Fix bug #334137
-rw-r--r-- | ChangeLog | 8 | ||||
-rw-r--r-- | libwnck/tasklist.c | 8 | ||||
-rw-r--r-- | libwnck/xutils.c | 2 |
3 files changed, 16 insertions, 2 deletions
@@ -1,3 +1,11 @@ +2006-03-25 Vincent Untz <vuntz@gnome.org> + + * libwnck/tasklist.c: (wnck_task_finalize): fix leaks + * libwnck/xutils.c: (_wnck_icon_cache_new): fill the structure with + lots of nice 0. + Patch by Dan Winship <danw@novell.com> + Fix bug #334137 + 2006-03-13 Vincent Untz <vuntz@gnome.org> * configure.in: post-release bump to 2.14.1 diff --git a/libwnck/tasklist.c b/libwnck/tasklist.c index fc14609..79efdca 100644 --- a/libwnck/tasklist.c +++ b/libwnck/tasklist.c @@ -561,7 +561,7 @@ wnck_task_finalize (GObject *object) if (task->menu) { - gtk_widget_destroy (task->menu); + g_object_unref (task->menu); task->menu = NULL; } @@ -597,6 +597,12 @@ wnck_task_finalize (GObject *object) task->button_activate = 0; } + if (task->screenshot) + { + g_object_unref (task->screenshot); + task->screenshot = NULL; + } + wnck_task_stop_glow (task); G_OBJECT_CLASS (task_parent_class)->finalize (object); diff --git a/libwnck/xutils.c b/libwnck/xutils.c index 49a5a1c..11463dc 100644 --- a/libwnck/xutils.c +++ b/libwnck/xutils.c @@ -1796,7 +1796,7 @@ _wnck_icon_cache_new (void) { WnckIconCache *icon_cache; - icon_cache = g_new (WnckIconCache, 1); + icon_cache = g_new0 (WnckIconCache, 1); icon_cache->origin = USING_NO_ICON; icon_cache->prev_pixmap = None; |