After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 638247 - Deadlock when enables an account
Deadlock when enables an account
Status: RESOLVED FIXED
Product: evolution-mapi
Classification: Applications
Component: miscellaneous
2.91.x
Other Linux
: High critical
: ---
Assigned To: evolution-mapi-maint
evolution-mapi-maint
Depends on:
Blocks:
 
 
Reported: 2010-12-29 07:46 UTC by Akhil Laddha
Modified: 2011-01-13 12:43 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
ema patch (22.16 KB, patch)
2011-01-13 12:41 UTC, Milan Crha
committed Details | Review

Description Akhil Laddha 2010-12-29 07:46:34 UTC
evolution 2.91.4
glib master
gtk 2.24
openchange r2134

I have account configured already which is disabled. When i go to edit -> preferences and enables the account, evolution becomes upresponsive and UI hangs completely.

gdb traces of evolution

(gdb) t a a bt

Thread 1 (Thread 0xb5fe6830 (LWP 4306))

  • #0 __kernel_vsyscall
  • #1 __lll_lock_wait
    from /lib/libpthread.so.0
  • #2 _L_lock_790
    from /lib/libpthread.so.0
  • #3 pthread_mutex_lock
    from /lib/libpthread.so.0
  • #4 g_static_rec_mutex_lock
    at gthread.c line 1424
  • #5 mapi_profile_create
    at exchange-mapi-connection.c line 3749
  • #6 exchange_mapi_create_profile
    at exchange-mapi-connection.c line 3867
  • #7 create_profile_entry
    at exchange-mapi-account-listener.c line 1013
  • #8 mapi_account_changed
    at exchange-mapi-account-listener.c line 1119
  • #9 g_cclosure_marshal_VOID__OBJECT
    at gmarshal.c line 638
  • #10 g_closure_invoke
    at gclosure.c line 767
  • #11 signal_emit_unlocked_R
    at gsignal.c line 3252
  • #12 g_signal_emit_valist
    at gsignal.c line 2983
  • #13 g_signal_emit
    at gsignal.c line 3040
  • #14 gconf_accounts_changed
    at e-account-list.c line 151
  • #15 notify_listeners_callback
    at gconf-client.c line 2444
  • #16 notify_listener_list
    at gconf-listeners.c line 590
  • #17 ltable_notify
    at gconf-listeners.c line 656
  • #18 gconf_listeners_notify
    at gconf-listeners.c line 185
  • #19 notify_one_entry
    at gconf-client.c line 2469
  • #20 gconf_client_flush_notifies
    at gconf-client.c line 2509
  • #21 notify_idle_callback
    at gconf-client.c line 2403
  • #22 g_idle_dispatch
    at gmain.c line 4536
  • #23 g_main_dispatch
    at gmain.c line 2440
  • #24 g_main_context_dispatch
    at gmain.c line 3013
  • #25 g_main_context_iterate
    at gmain.c line 3091
  • #26 g_main_loop_run
    at gmain.c line 3299
  • #27 IA__gtk_main
    at gtkmain.c line 1240
  • #28 main
    at main.c line 734

Comment 1 Akhil Laddha 2010-12-29 07:48:57 UTC
Similar hang when tried to enable another account

Thread 1 (Thread 0xb5fe6830 (LWP 24413))

  • #0 __kernel_vsyscall
  • #1 __lll_lock_wait
    from /lib/libpthread.so.0
  • #2 _L_lock_790
    from /lib/libpthread.so.0
  • #3 pthread_mutex_lock
    from /lib/libpthread.so.0
  • #4 g_static_rec_mutex_lock
    at gthread.c line 1424
  • #5 exchange_mapi_delete_profile
    at exchange-mapi-connection.c line 3875
  • #6 mapi_account_removed
    at exchange-mapi-account-listener.c line 968
  • #7 mapi_account_changed
    at exchange-mapi-account-listener.c line 1118
  • #8 g_cclosure_marshal_VOID__OBJECT
    at gmarshal.c line 638
  • #9 g_closure_invoke
    at gclosure.c line 767
  • #10 signal_emit_unlocked_R
    at gsignal.c line 3252
  • #11 g_signal_emit_valist
    at gsignal.c line 2983
  • #12 g_signal_emit
    at gsignal.c line 3040
  • #13 gconf_accounts_changed
    at e-account-list.c line 151
  • #14 notify_listeners_callback
    at gconf-client.c line 2444
  • #15 notify_listener_list
    at gconf-listeners.c line 590
  • #16 ltable_notify
    at gconf-listeners.c line 656
  • #17 gconf_listeners_notify
    at gconf-listeners.c line 185
  • #18 notify_one_entry
    at gconf-client.c line 2469
  • #19 gconf_client_flush_notifies
    at gconf-client.c line 2509
  • #20 notify_idle_callback
    at gconf-client.c line 2403
  • #21 g_idle_dispatch
    at gmain.c line 4536
  • #22 g_main_dispatch
    at gmain.c line 2440
  • #23 g_main_context_dispatch
    at gmain.c line 3013
  • #24 g_main_context_iterate
    at gmain.c line 3091
  • #25 g_main_loop_run
    at gmain.c line 3299
  • #26 IA__gtk_main
    at gtkmain.c line 1240
  • #27 main
    at main.c line 734

Comment 2 Milan Crha 2011-01-13 08:45:10 UTC
Confirming. Steps:
a) disable MAPI account
b) close all evolution-related processes
c) delete ~/.local/share/evolution/mapi-profiles.ldb
d) run evolution
e) Edit->Preferences->Mail Accounts->enable MAPI account
Comment 3 Milan Crha 2011-01-13 12:41:47 UTC
Created attachment 178217 [details] [review]
ema patch

for evolution-mapi;

Doing couple things in an extra thread and other couple things in the main thread fixes the deadlock. The code complexity increased slightly, but in a good manner.
Comment 4 Milan Crha 2011-01-13 12:43:06 UTC
Crated commit dad54aa in ema master (2.91.6+)