From b3726e4d66953d6ed73ff4e200cea83660307a3e Mon Sep 17 00:00:00 2001 From: Emmanuele Bassi Date: Tue, 23 Sep 2008 12:58:31 +0000 Subject: [PATCH] 2008-09-23 Emmanuele Bassi * clutter/clutter-timeout-pool.c: (clutter_timeout_pool_new): Fix previous commit: g_source_unref() is not needed. (Thanks to Neil Roberts) --- ChangeLog | 6 ++++++ clutter/clutter-timeout-pool.c | 8 ++++++-- 2 files changed, 12 insertions(+), 2 deletions(-) diff --git a/ChangeLog b/ChangeLog index 3f13e9b5c..d3abc828e 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,9 @@ +2008-09-23 Emmanuele Bassi + + * clutter/clutter-timeout-pool.c: + (clutter_timeout_pool_new): Fix previous commit: g_source_unref() + is not needed. (Thanks to Neil Roberts) + 2008-09-23 Emmanuele Bassi Bug 1154 - clutter_timeout_pool_new() documentation doesn't say diff --git a/clutter/clutter-timeout-pool.c b/clutter/clutter-timeout-pool.c index 169186a69..560ff4ff7 100644 --- a/clutter/clutter-timeout-pool.c +++ b/clutter/clutter-timeout-pool.c @@ -422,8 +422,9 @@ clutter_timeout_pool_finalize (GSource *source) * Inside Clutter, every #ClutterTimeline share the same timeout pool, unless * the CLUTTER_TIMELINE=no-pool environment variable is set. * - * Return value: the newly created #ClutterTimeoutPool. Use g_source_unref() - * to release the resources allocated by this function + * Return value: the newly created #ClutterTimeoutPool. The created pool + * is owned by the GLib default context and should not be unreferenced + * or freed * * Since: 0.4 */ @@ -442,9 +443,12 @@ clutter_timeout_pool_new (gint priority) g_source_set_priority (source, priority); pool = (ClutterTimeoutPool *) source; + g_get_current_time (&pool->start_time); pool->next_id = 1; pool->id = g_source_attach (source, NULL); + + /* let the default GLib context manage the pool */ g_source_unref (source); return pool;