Changeset 1773

Show
Ignore:
Timestamp:
03/30/07 18:51:35
Author:
pvanhoof
Message:

Added a funny lock

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • trunk/libtinymailui-gtk/tny-gtk-header-list-model.c

    r1772 r1773  
    378378        g_static_rec_mutex_lock (list_model->iterator_lock); 
    379379 
     380        g_static_rec_mutex_lock (list_model->ra_l_lock); 
    380381        if (G_LIKELY (!iter)) 
    381382                retval = list_model->items->len; 
     383        g_static_rec_mutex_unlock (list_model->ra_l_lock); 
    382384 
    383385        g_static_rec_mutex_unlock (list_model->iterator_lock); 
     
    447449        me->updating_views = -1; 
    448450        g_mutex_unlock (me->ra_lock); 
     451 
     452        g_static_rec_mutex_unlock (me->ra_l_lock); 
    449453        g_object_unref (me); 
    450454 
     
    458462        GtkTreePath *path; 
    459463        gboolean needmore = FALSE; 
     464 
     465        g_static_rec_mutex_lock (me->ra_l_lock); 
    460466 
    461467        g_mutex_lock (me->ra_lock); 
     
    701707        g_static_rec_mutex_free (self->iterator_lock); 
    702708        self->iterator_lock = NULL; 
     709 
     710        g_static_rec_mutex_free (self->ra_l_lock); 
     711        self->ra_l_lock = NULL; 
     712 
    703713        g_mutex_free (self->ra_lock); 
    704714        self->ra_lock = NULL; 
     
    729739        self->iterator_lock = g_new0 (GStaticRecMutex, 1); 
    730740        g_static_rec_mutex_init (self->iterator_lock); 
     741        self->ra_l_lock = g_new0 (GStaticRecMutex, 1); 
     742        g_static_rec_mutex_init (self->ra_l_lock); 
     743 
    731744        self->items = g_ptr_array_sized_new (1000); 
    732745        self->updating_views = -1; 
  • trunk/libtinymailui-gtk/tny-gtk-header-list-model.h

    r1769 r1773  
    6464        GObject parent; 
    6565 
    66         GStaticRecMutex *iterator_lock
     66        GStaticRecMutex *iterator_lock, *ra_l_lock
    6767        TnyFolder *folder; 
    6868        gint stamp, recent_updated;