Bug 1173497

Summary: Reuse existing ESourceRegistry from EMailSession, if available
Product: Red Hat Enterprise Linux 7 Reporter: Milan Crha <mcrha>
Component: evolution-ewsAssignee: Matthew Barnes <mbarnes>
Status: CLOSED DUPLICATE QA Contact: Desktop QE <desktop-qa-list>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 7.0CC: desktop-qa-list, martinsson.patrik, mbarnes, mcrha, vbenes
Target Milestone: rc   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: 1172143 Environment:
Last Closed: 2015-05-04 17:02:43 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On: 1172143    
Bug Blocks:    

Description Milan Crha 2014-12-12 09:47:24 UTC
+++ This bug was initially created as a clone of Bug #1172143 +++

The problem is that the evolution-ews is creating its own instance of an ESourceRegistry, at the place shown in the below backtrace. This ESourceRegistry has scheduled the source_registry_source_notify_enabled_idle_cb() while the 'registry' object is disposing, which later leads to the crash when using already freed data in the callback. I'm checking how to fix this in the most sane way.

#6  0x00007ffff52d62f3 in e_source_registry_new_sync (cancellable=0x0, error=0x0) at e-source-registry.c:1677
#7  0x00007fffd27c529b in ews_store_maybe_update_sent_and_drafts (ews_store=0x13ebf30, ews_folders=0xc1d2b0 = {...}) at camel-ews-store.c:904
#8  0x00007fffd27c5d16 in ews_authenticate_sync (service=0x13ebf30, mechanism=0x7fff98008190 "NTLM", cancellable=0x1488c90, error=0x7fffad325920) at camel-ews-store.c:1124
#9  0x00007ffff489476e in camel_service_authenticate_sync (service=0x13ebf30, mechanism=0x7fff98008190 "NTLM", cancellable=0x1488c90, error=0x7fffad325920) at camel-service.c:2017
#10 0x00007fffd1ef1ab0 in mail_authenticator_try_password_sync (auth=0x14a7540, password=0x7fffc8404e80, cancellable=0x1488c90, error=0x7fffad325920) at e-mail-authenticator.c:165
#11 0x00007ffff52c750f in e_source_authenticator_try_password_sync (auth=0x14a7540, password=0x7fffc8404e80, cancellable=0x1488c90, error=0x7fffad325920) at e-source-authenticator.c:418
#12 0x00007ffff52d6747 in source_registry_authenticate_authenticate_cb (dbus_auth=0x13d5960,

Comment 1 Milan Crha 2014-12-12 10:23:53 UTC
Corresponding upstream fix:
https://git.gnome.org/browse/evolution-ews/commit/?id=fc99a07

Comment 3 Milan Crha 2015-05-04 17:02:43 UTC
The fix is already included in the rebased 3.12.11, thus I mark this as a duplicate of it.

*** This bug has been marked as a duplicate of bug 1174417 ***