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 664174 - [abrt] Crash in add_item_to_cache()
[abrt] Crash in add_item_to_cache()
Status: RESOLVED FIXED
Product: evolution-ews
Classification: Other
Component: Calendar
3.8.x
Other Linux
: Normal critical
: ---
Assigned To: Evolution EWS maintainer(s)
Evolution EWS maintainer(s)
Depends on:
Blocks:
 
 
Reported: 2011-11-16 07:45 UTC by Milan Crha
Modified: 2013-11-22 11:18 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
ews patch (877 bytes, patch)
2013-11-22 11:15 UTC, Milan Crha
committed Details | Review

Description Milan Crha 2011-11-16 07:45:02 UTC
Moving this from a downstream bug report:
https://bugzilla.redhat.com/show_bug.cgi?id=754080

libreport version: 2.0.6
abrt_version:   2.0.4.981
backtrace_rating: 4
cmdline:        /usr/libexec/e-calendar-factory
comment:        Logged in to system and got error message.
crash_function: ____strtol_l_internal
executable:     /usr/libexec/e-calendar-factory
kernel:         3.1.1-1.fc16.x86_64
reason:         Process /usr/libexec/e-calendar-factory was killed by signal 11
(SIGSEGV)
time:           Tue Nov 15 15:11:11 2011

Core was generated by `/usr/libexec/e-calendar-factory'.
Program terminated with signal 11, Segmentation fault.

Thread 2 (Thread 0x7f0e3ba82700 (LWP 1979))

  • #0 read
    at ../sysdeps/unix/syscall-template.S line 82
  • #1 read
    at /usr/include/bits/unistd.h line 45
  • #2 unix_signal_helper_thread
    at gmain.c line 4551
  • #3 g_thread_create_proxy
    at gthread.c line 1962
  • #4 start_thread
    at pthread_create.c line 309
  • #5 clone
    at ../sysdeps/unix/sysv/linux/x86_64/clone.S line 115

Comment 1 Milan Crha 2012-06-11 08:56:51 UTC
Similar crash from 3.4.1:
https://bugzilla.redhat.com/show_bug.cgi?id=830186

Thread 1 (Thread 0x7f378e9d7800 (LWP 1845))

  • #0 __GI_____strtol_l_internal
    at ../stdlib/strtol_l.c line 298
  • #1 __GI_strtol
    at ../stdlib/strtol.c line 110
  • #2 atoi
    at /usr/include/stdlib.h line 286
  • #3 add_item_to_cache
    at e-cal-backend-ews.c line 2865
  • #4 ews_cal_get_items_ready_cb
    at e-cal-backend-ews.c line 3230
  • #5 g_simple_async_result_complete
    at gsimpleasyncresult.c line 767
  • #6 complete_in_idle_cb
    at gsimpleasyncresult.c line 779
  • #7 g_main_dispatch
    at gmain.c line 2539
  • #8 g_main_context_dispatch
    at gmain.c line 3075
  • #9 g_main_context_iterate
    at gmain.c line 3146
  • #10 g_main_loop_run
    at gmain.c line 3340
  • #11 e_dbus_server_run
    at e-dbus-server.c line 253
  • #12 main
    at evolution-calendar-factory.c line 149

Comment 2 Milan Crha 2012-06-11 09:00:17 UTC
It'll be good to get actual data returned from the server, to see what was evolution-ews parsing and why it failed. You can achieve that by running evolution-calendar-factory by this command from the terminal:
   $ EWS_DEBUG=2 /usr/libexec/evolution-calendar-factory -w &>log.txt
Please make sure there is not other factory running already, same as no evolution.
Comment 3 Milan Crha 2013-08-27 14:39:52 UTC
I'm closing this, no response given, no duplicates since 3.4.x found, thus let's try with 3.8.x or later.
Comment 4 Milan Crha 2013-11-22 10:31:22 UTC
Reopening, due to a downstream bug report from 3.8.5:
https://bugzilla.redhat.com/show_bug.cgi?id=1032907

The crash happens on a line 3367, when parsing a Task:
3366   /*precent complete*/
3367   icalprop  = icalproperty_new_percentcomplete (atoi 
       (e_ews_item_get_percent_complete (item)));
3368   icalcomponent_add_property (icalcomp, icalprop);

Thread 1 (Thread 0x7fc46e7fc700 (LWP 24034))

  • #0 __GI_____strtol_l_internal
    at ../stdlib/strtol_l.c line 298
  • #1 __GI_strtol
    at ../stdlib/strtol.c line 109
  • #2 atoi
    at /usr/include/stdlib.h line 280
  • #3 add_item_to_cache
    at e-cal-backend-ews.c line 3367
  • #4 ews_cal_sync_get_items_sync
    at e-cal-backend-ews.c line 3713
  • #5 cal_backend_ews_process_folder_items
    at e-cal-backend-ews.c line 3777
  • #6 ews_start_sync_thread
    at e-cal-backend-ews.c line 3865
  • #7 g_thread_proxy
    at gthread.c line 798
  • #8 start_thread
    at pthread_create.c line 308
  • #9 clone
    at ../sysdeps/unix/sysv/linux/x86_64/clone.S line 113

Comment 5 Milan Crha 2013-11-22 11:15:13 UTC
Created attachment 261225 [details] [review]
ews patch

for evolution-ews;

I cannot reproduce this, but as the last backtrace gave a clear place, and the fix is basically straightforward, then I'm committing this change, which prevents the crash if the PercentComplete property is not available on a Task item. If I would guess, then probably some other client (maybe evo-mapi) didn't set the PercentComplete property at all, thus it was not available in the EWS XML response. But that's just a guess.
Comment 6 Milan Crha 2013-11-22 11:18:09 UTC
Created commit 0d4634b in ews master (3.11.3+)
Created commit efd07d8 in ews gnome-3-10 (3.10.3+)