[libchamplain] wait until every thread has finished (potential leak)
- From: Pierre-Luc Beaudoin <plbeaudoin src gnome org>
- To: svn-commits-list gnome org
- Cc:
- Subject: [libchamplain] wait until every thread has finished (potential leak)
- Date: Sun, 24 Jan 2010 20:07:19 +0000 (UTC)
commit 496b8b3e359d4399bd5991a168d73711e9f05e1e
Author: Simon Wenner <simon wenner ch>
Date: Wed Jun 24 11:23:41 2009 +0200
wait until every thread has finished (potential leak)
champlain/champlain-memphis-map-source.c | 9 +++++----
1 files changed, 5 insertions(+), 4 deletions(-)
---
diff --git a/champlain/champlain-memphis-map-source.c b/champlain/champlain-memphis-map-source.c
index 4a419bf..39c15e0 100644
--- a/champlain/champlain-memphis-map-source.c
+++ b/champlain/champlain-memphis-map-source.c
@@ -96,6 +96,9 @@ champlain_memphis_map_source_dispose (GObject *object)
ChamplainMemphisMapSource *self = (ChamplainMemphisMapSource *) object;
ChamplainMemphisMapSourcePrivate *priv = GET_PRIVATE(self);
+ if (priv->thpool)
+ g_thread_pool_free (priv->thpool, FALSE, TRUE);
+
if (priv->map_data_source)
g_object_unref (priv->map_data_source);
memphis_renderer_free (priv->renderer);
@@ -107,10 +110,8 @@ champlain_memphis_map_source_dispose (GObject *object)
static void
champlain_memphis_map_source_finalize (GObject *object)
{
- ChamplainMemphisMapSource *self = (ChamplainMemphisMapSource *) object;
- ChamplainMemphisMapSourcePrivate *priv = GET_PRIVATE(self);
-
- g_thread_pool_free (priv->thpool, TRUE, TRUE);
+ //ChamplainMemphisMapSource *self = (ChamplainMemphisMapSource *) object;
+ //ChamplainMemphisMapSourcePrivate *priv = GET_PRIVATE(self);
G_OBJECT_CLASS (champlain_memphis_map_source_parent_class)->finalize (object);
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]