[cheese] cheese-thumb-view: guard thread unsafe operations



commit 9151f56c7a15fe03e4bf6e7e7e9cce0c9fd6bce1
Author: Luciana Fujii Pontello <luciana fujii eti br>
Date:   Tue Apr 19 14:50:44 2011 -0300

    cheese-thumb-view: guard thread unsafe operations
    
    Cheese was crashing in gtk_icon_theme_load_icon because there were
    operations that are not thread safe that were done before
    gdk_threads_enter.

 src/thumbview/cheese-thumb-view.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)
---
diff --git a/src/thumbview/cheese-thumb-view.c b/src/thumbview/cheese-thumb-view.c
index 19ddeda..505f40a 100644
--- a/src/thumbview/cheese-thumb-view.c
+++ b/src/thumbview/cheese-thumb-view.c
@@ -139,6 +139,8 @@ cheese_thumb_view_thread_append_item (gpointer data)
   g_free (thumb_loc);
   g_free (uri);
 
+  gdk_threads_enter ();
+
   if (!pixbuf)
   {
     gchar  *escape = NULL;
@@ -161,8 +163,6 @@ cheese_thumb_view_thread_append_item (gpointer data)
     cheese_thumbnail_add_frame (&pixbuf);
   }
 
-  gdk_threads_enter ();
-
   gtk_list_store_set (priv->store, &iter,
                       THUMBNAIL_PIXBUF_COLUMN, pixbuf, -1);
 



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]