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 634285 - [abrt] Crash in cfs_try_release_memory()
[abrt] Crash in cfs_try_release_memory()
Status: RESOLVED OBSOLETE
Product: evolution
Classification: Applications
Component: Mailer
3.10.x (obsolete)
Other Linux
: Normal critical
: ---
Assigned To: evolution-mail-maintainers
Evolution QA team
: 648092 648513 649163 (view as bug list)
Depends on:
Blocks:
 
 
Reported: 2010-11-08 08:30 UTC by Milan Crha
Modified: 2015-03-10 17:26 UTC
See Also:
GNOME target: ---
GNOME version: ---



Description Milan Crha 2010-11-08 08:30:26 UTC
Moving this from a downstream bugzilla:
https://bugzilla.redhat.com/show_bug.cgi?id=650269

abrt version: 1.1.13
architecture: i686
Attached file: backtrace
cmdline: evolution
component: evolution
crash_function: cfs_try_release_memory
executable: /usr/bin/evolution
kernel: 2.6.35.6-48.fc14.i686
package: evolution-2.32.0-2.fc14
rating: 4
reason: Process /usr/bin/evolution was killed by signal 11 (SIGSEGV)
release: Fedora release 14 (Laughlin)
time: 1288973870
uid: 500

How to reproduce
-----
1. using mouse pointer on scroll bar

Core was generated by `evolution'.
Program terminated with signal 11, Segmentation fault.

Thread 1 (Thread 9859)

  • #0 cfs_try_release_memory
    at camel-folder-summary.c line 1573
  • #1 g_timeout_dispatch
    at gmain.c line 3585
  • #2 g_main_dispatch
    at gmain.c line 2149
  • #3 g_main_context_dispatch
    at gmain.c line 2702
  • #4 g_main_context_iterate
    at gmain.c line 2780
  • #5 g_main_loop_run
    at gmain.c line 2988
  • #6 IA__gtk_main
    at gtkmain.c line 1237
  • #7 main
    at main.c line 671

Comment 1 Akhil Laddha 2010-12-10 10:39:33 UTC
I got similar crash in master (2.91.3)

(evolution:2901): camel-CRITICAL **: camel_folder_get_parent_store: assertion `CAMEL_IS_FOLDER (folder)' failed

Program received signal SIGSEGV, Segmentation fault.
0xb7b62b79 in cfs_try_release_memory (s=0xa9b491a0)
    at camel-folder-summary.c:1569
1569		session = CAMEL_SERVICE (parent_store)->session;
(gdb) t a a bt

Thread 1 (Thread 0xb5ff9830 (LWP 2901))

  • #0 cfs_try_release_memory
    at camel-folder-summary.c line 1569
  • #1 g_timeout_dispatch
    at gmain.c line 3877
  • #2 g_main_dispatch
    at gmain.c line 2440
  • #3 g_main_context_dispatch
    at gmain.c line 3013
  • #4 g_main_context_iterate
    at gmain.c line 3091
  • #5 g_main_loop_run
    at gmain.c line 3299
  • #6 IA__gtk_main
    at gtkmain.c line 1238
  • #7 main
    at main.c line 698
  • #0 cfs_try_release_memory
    at camel-folder-summary.c line 1569
  • #1 g_timeout_dispatch
    at gmain.c line 3877
  • #2 g_main_dispatch
    at gmain.c line 2440
  • #3 g_main_context_dispatch
    at gmain.c line 3013
  • #4 g_main_context_iterate
    at gmain.c line 3091
  • #5 g_main_loop_run
    at gmain.c line 3299
  • #6 IA__gtk_main
    at gtkmain.c line 1238
  • #7 main
    at main.c line 698
        error = 0x0
(gdb) l
1564			s->timeout_handle = 0;
1565			return FALSE;
1566		}
1567	
1568		parent_store = camel_folder_get_parent_store (s->folder);
1569		session = CAMEL_SERVICE (parent_store)->session;
1570	
1571		if (time (NULL) - s->cache_load_time < SUMMARY_CACHE_DROP)
1572			return TRUE;
1573	
(gdb) p s->folder
$1 = (struct _CamelFolder *) 0x8a5a6c0
(gdb) p *s->folder
$2 = {parent = {parent = {g_type_instance = {g_class = 0xaa1a0820}, 
      ref_count = 3476802158, qdata = 0xaaaaaaaa}, priv = 0xaaaaaaaa}, 
  priv = 0xaaaaaaaa, summary = 0xaaaaaaaa, folder_flags = 2863311530, 
  permanent_flags = -1431655766, later = {0xaaaaaaaa, 0xaaaaaaaa, 0xaaaaaaaa, 
    0xaaaaaaaa}}
(gdb) p G_OBJECT_TYPE_NAME(s)
No symbol "G_OBJECT_TYPE_NAME" in current context.
(gdb) p *s
$3 = {parent = {parent = {g_type_instance = {g_class = 0x847d658}, 
      ref_count = 4, qdata = 0x0}, priv = 0xa9b49230}, priv = 0xa9b49238, 
  version = 14, flags = 0, nextuid = 6, time = 0, saved_count = 5, 
  unread_count = 0, deleted_count = 0, junk_count = 0, 
  junk_not_deleted_count = 0, visible_count = 5, message_info_chunks = 0x0, 
  content_info_chunks = 0x0, 
  summary_path = 0x8497308 "/home/lakhil/.local/share/evolution/mail/maildir/.Copy.ev-summary", build_content = 0, uids = 0x89f51b0, loaded_infos = 0x91edb50, 
  folder = 0x8a5a6c0, meta_summary = 0x89b76d8, cache_load_time = 1291966949, 
  timeout_handle = 160745, collate = 0x0, sort_by = 0xad6b25ae "dreceived", 
  later = {0x0, 0x0, 0x0, 0x0}}
(gdb) p s->parent.parent.g_type_instance 
$4 = {g_class = 0x847d658}
(gdb) p *s->parent.parent.g_type_instance.g_class 
$5 = {g_type = 138925088}
(gdb) p g_type_name(s->parent.parent.g_type_instance.g.Type struct _GTypeInstance has no component named g.
(gdb) p *s->parent.parent.g_type_instance.g_class.g_type 
$6 = 15
(gdb) p g_type_name(s->parent.parent.g_type_instance.g_class.g_type)
$7 = (gchar *) 0xad6b2590 "CamelMaildirSummary"
Comment 2 Milan Crha 2010-12-10 18:37:23 UTC
Hrm, I cannot reproduce this, neither when cheating the code (by lowering eds/camel/camel-folder-summary.c:SUMMARY_CACHE_DROP to say 5 seconds). The above shows that the summary survived its folder, and from the code it seems that is not possible unless something reffed the folder->summary somewhere and forgot to unref it again (forgot or something else failed before it was able to unref it). So we depend on actual operation here, which is causing this.

I see it's doing on a regular maildir folder, named Copy in Akhil's case.

The problem is that I do not know how to track this down at the moment. Maybe if some steps are available, the best in offline mode...
Comment 3 Tobias Mueller 2011-03-16 09:29:15 UTC
Hm. Is there any way to reproduce this issue?
Comment 4 Akhil Laddha 2011-04-18 11:05:19 UTC
*** Bug 648092 has been marked as a duplicate of this bug. ***
Comment 5 Ross Burton 2011-04-20 11:23:24 UTC
I'm getting this frequently with 2.32 and maildirs.  I can replicate by simply having evolution open and doing nothing.

(gdb) bt
  • #0 cfs_try_release_memory
    at camel-folder-summary.c line 1576
  • #1 g_timeout_dispatch
    at /tmp/buildd/glib2.0-2.28.6/./glib/gmain.c line 3882
  • #2 g_main_dispatch
    at /tmp/buildd/glib2.0-2.28.6/./glib/gmain.c line 2440
  • #3 g_main_context_dispatch
    at /tmp/buildd/glib2.0-2.28.6/./glib/gmain.c line 3013
  • #4 g_main_context_iterate
    at /tmp/buildd/glib2.0-2.28.6/./glib/gmain.c line 3091
  • #5 g_main_loop_run
    at /tmp/buildd/glib2.0-2.28.6/./glib/gmain.c line 3299
  • #6 gtk_main
    from /usr/lib/libgtk-x11-2.0.so.0
  • #7 main
    at main.c line 679
$1 = (CamelFolderSummary *) 0x7fa323d299b0
(gdb) print *s
$2 = {parent = {parent = {g_type_instance = {g_class = 0x7fa323d26860}, 
      ref_count = 228, qdata = 0x0}, priv = 0x7fa323d29ab0}, 
  priv = 0x7fa323d29ac0, version = 14, flags = 0, nextuid = 2, time = 0, 
  saved_count = 680, unread_count = 0, deleted_count = 588, junk_count = 0, 
  junk_not_deleted_count = 0, visible_count = 92, message_info_chunks = 0x0, 
  content_info_chunks = 0x0, 
  summary_path = 0x7fa323b21f90 "/home/ross/Mail/LinuxIntel/Linux.ev-summary", 
  build_content = 0, uids = 0x7fa323fd1160, loaded_infos = 0x7fa3236fbd90, 
  folder = 0x7fa323e079c0, meta_summary = 0x7fa323b20490, 
  cache_load_time = 1303298074, timeout_handle = 145, collate = 0x0, 
  sort_by = 0x7fa30319d840 "dreceived", later = {0x0, 0x0, 0x0, 0x0}}
Comment 6 Srinivasa Ragavan 2011-04-20 13:29:59 UTC
(In reply to comment #2)
> Hrm, I cannot reproduce this, neither when cheating the code (by lowering
> eds/camel/camel-folder-summary.c:SUMMARY_CACHE_DROP to say 5 seconds). The
> above shows that the summary survived its folder, and from the code it seems
> that is not possible unless something reffed the folder->summary somewhere and
> forgot to unref it again (forgot or something else failed before it was able to
> unref it). So we depend on actual operation here, which is causing this.
> 
> I see it's doing on a regular maildir folder, named Copy in Akhil's case.
> 
> The problem is that I do not know how to track this down at the moment. Maybe
> if some steps are available, the best in offline mode...

Milan, I think the vfolders ref the summary, but not the folder and I don't see how it unrefs it when the folder dies. 
Checkup camel-vee-summary.c:camel_vee_summary_add

Ross's vfolders are off, but still trash/junk could cause this. 

Ross: to confirm, can you empty trash & delete/expunge junk and see if you can reproduce the bug?
Comment 7 Ross Burton 2011-04-20 13:36:29 UTC
I'd love to, but if I try to expunge my maildirs then evolution locks up.
Comment 8 Akhil Laddha 2011-04-24 02:25:36 UTC
*** Bug 648513 has been marked as a duplicate of this bug. ***
Comment 9 André Klapper 2011-05-02 11:53:46 UTC
*** Bug 649163 has been marked as a duplicate of this bug. ***
Comment 10 Milan Crha 2012-06-11 06:53:33 UTC
Hmm, I just got this with IMAP folder in git master (before 3.5.3) with the below backtrace. The console showed:
(evolution:31850): camel-CRITICAL **: camel_folder_get_parent_store: assertion `CAMEL_IS_FOLDER (folder)' failed

(evolution:31850): camel-CRITICAL **: camel_service_get_session: assertion `CAMEL_IS_SERVICE (service)' failed

Thread 1 (Thread 0x7f2bd02b0a00 (LWP 31850))

  • #0 waitpid
    from /lib64/libpthread.so.0
  • #1 g_spawn_sync
    at gspawn.c line 405
  • #2 g_spawn_command_line_sync
    at gspawn.c line 722
  • #3 run_bug_buddy
    at gnome-segvhanlder.c line 240
  • #4 bugbuddy_segv_handle
    at gnome-segvhanlder.c line 191
  • #5 <signal handler called>
  • #6 camel_folder_get_parent_store
    at camel-folder.c line 2104
  • #7 cfs_try_release_memory
    at camel-folder-summary.c line 2053
  • #8 g_timeout_dispatch
    at gmain.c line 3859
  • #9 g_main_dispatch
    at gmain.c line 2515
  • #10 g_main_context_dispatch
    at gmain.c line 3052
  • #11 g_main_context_iterate
    at gmain.c line 3123
  • #12 g_main_loop_run
    at gmain.c line 3317
  • #13 gtk_main
    at gtkmain.c line 1161
  • #14 main
    at main.c line 679

Comment 11 Milan Crha 2012-06-13 10:22:38 UTC
Bad, I cannot reproduce it now. I tried to debug this and it seems fine. I see only one possible issue, that is the disable of the cfs_try_release_memory() callback, which is done only in finalize, while most of the internal (priv) members are gone in dispose. I do not know whether that is the case, but it might be. I committed changes for this, and I'm closing this bug too. I'll reopen (or you please do) in case I/you'll be able to reproduce this again.

Created commit ec57923 in eds master (3.5.3+)
Created commit be57410 in eds gnome-3-4 (3.4.3+)
Comment 12 Milan Crha 2012-08-31 08:56:30 UTC
Reopening, downstream bug report from 3.4.3:
https://bugzilla.redhat.com/show_bug.cgi?id=853174

Thread 1 (Thread 0x7f24c913d9c0 (LWP 1710))

  • #0 g_type_check_instance_is_a
    at gtype.c line 3966
  • #1 camel_folder_get_parent_store
    at camel-folder.c line 2072
  • #2 cfs_try_release_memory
    at camel-folder-summary.c line 1967
  • #3 cfs_try_release_memory
    at camel-folder-summary.c line 1955
  • #4 g_timeout_dispatch
    at gmain.c line 3882
  • #5 g_main_dispatch
    at gmain.c line 2539
  • #6 g_main_context_dispatch
    at gmain.c line 3075
  • #7 g_main_context_iterate
    at gmain.c line 3146
  • #8 g_main_loop_run
    at gmain.c line 3340
  • #9 gtk_main
    at gtkmain.c line 1161
  • #10 main
    at main.c line 681

Comment 13 Milan Crha 2013-07-12 09:03:22 UTC
One similar downstream bug report from 3.8.3 involving evolution-ews:
https://bugzilla.redhat.com/show_bug.cgi?id=983678

Thread 1 (Thread 0xb7451900 (LWP 2315))

  • #0 camel_folder_summary_content_info_free
    at camel-folder-summary.c line 3296
  • #1 camel_message_info_free
    at camel-folder-summary.c line 4625
  • #2 g_slist_foreach
    at gslist.c line 896
  • #3 remove_all_loaded
    at camel-folder-summary.c line 195
  • #4 folder_summary_finalize
    at camel-folder-summary.c line 280
  • #5 ews_summary_finalize
    at camel-ews-summary.c line 96
  • #6 g_object_unref
    at gobject.c line 3024
  • #7 cfs_try_release_memory
    at camel-folder-summary.c line 2116
  • #8 g_timeout_dispatch
    at gmain.c line 4413
  • #9 g_main_dispatch
    at gmain.c line 3054
  • #10 g_main_context_dispatch
    at gmain.c line 3630
  • #11 g_main_context_iterate
    at gmain.c line 3701
  • #12 g_main_loop_run
    at gmain.c line 3895
  • #13 gtk_main
    at gtkmain.c line 1156
  • #14 main
    at main.c line 707

Comment 14 Milan Crha 2013-09-30 08:34:54 UTC
Even in 3.10.0:
https://bugzilla.redhat.com/show_bug.cgi?id=1013217
Comment 15 Milan Crha 2015-03-10 17:26:06 UTC
No duplicate for a long time, I'm closing this.