From aa9dd5bfb5ea0ca5d0a0e5be577f2e028d0549ee Mon Sep 17 00:00:00 2001 From: Carlos Garcia Campos Date: Sun, 11 Feb 2007 17:06:41 +0000 Subject: [PATCH] Fix invalid free in ev-page-cache. Fixes bug #404745. 2007-02-11 Carlos Garcia Campos * shell/ev-page-cache.c: (ev_page_cache_finalize): Fix invalid free in ev-page-cache. Fixes bug #404745. svn path=/trunk/; revision=2313 --- ChangeLog | 6 ++++++ shell/ev-page-cache.c | 8 +++++++- 2 files changed, 13 insertions(+), 1 deletion(-) diff --git a/ChangeLog b/ChangeLog index 367d9f7a..3ed2f7bc 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,9 @@ +2007-02-11 Carlos Garcia Campos + + * shell/ev-page-cache.c: (ev_page_cache_finalize): + + Fix invalid free in ev-page-cache. Fixes bug #404745. + 2007-02-11 Nickolay V. Shmyrev * test/Makefile.am: diff --git a/shell/ev-page-cache.c b/shell/ev-page-cache.c index 01164520..ebf0de7f 100644 --- a/shell/ev-page-cache.c +++ b/shell/ev-page-cache.c @@ -129,7 +129,13 @@ ev_page_cache_finalize (GObject *object) } if (page_cache->page_labels) { - g_strfreev (page_cache->page_labels); + gint i; + + for (i = 0; i < page_cache->n_pages; i++) { + if (page_cache->page_labels[i]) + g_free (page_cache->page_labels[i]); + } + g_free (page_cache->page_labels); page_cache->page_labels = NULL; } -- 2.43.5