Bug 8487 - [SGEN] pointer being freed was not allocated
Summary: [SGEN] pointer being freed was not allocated
Status: RESOLVED DUPLICATE of bug 4595
Alias: None
Product: Runtime
Classification: Mono
Component: GC ()
Version: unspecified
Hardware: PC Mac OS
: --- normal
Target Milestone: ---
Assignee: Bugzilla
URL:
Depends on:
Blocks:
 
Reported: 2012-11-18 20:29 UTC by Alex Corrado [MSFT]
Modified: 2013-05-23 12:09 UTC (History)
3 users (show)

Tags:
Is this bug a regression?: ---
Last known good build:

Notice (2018-05-24): bugzilla.xamarin.com is now in read-only mode.

Please join us on Visual Studio Developer Community and in the Xamarin and Mono organizations on GitHub to continue tracking issues. Bugzilla will remain available for reference in read-only mode. We will continue to work on open Bugzilla bugs, copy them to the new locations as needed for follow-up, and add the new items under Related Links.

Our sincere thanks to everyone who has contributed on this bug tracker over the years. Thanks also for your understanding as we make these adjustments and improvements for the future.


Please create a new report on GitHub or Developer Community with your current version information, steps to reproduce, and relevant error messages or log files if you are hitting an issue that looks similar to this resolved bug and you do not yet see a matching new report.

Related Links:
Status:
RESOLVED DUPLICATE of bug 4595

Description Alex Corrado [MSFT] 2012-11-18 20:29:05 UTC
Crash happened when quitting MonoDevelop. Looks related to freeing dynamic methods. Here's the relevant part of the crash log:

Crashed Thread:  0  Dispatch queue: com.apple.main-thread

Exception Type:  EXC_CRASH (SIGABRT)
Exception Codes: 0x0000000000000000, 0x0000000000000000

Application Specific Information:
*** error for object 0x7b972db0: pointer being freed was not allocated
 

Thread 0 Crashed:: Dispatch queue: com.apple.main-thread
0   libsystem_kernel.dylib        	0x92151a6a __pthread_kill + 10
1   libsystem_c.dylib             	0x97685acf pthread_kill + 101
2   libsystem_c.dylib             	0x976bc5ff __abort + 199
3   libsystem_c.dylib             	0x976bc538 abort + 232
4   libsystem_c.dylib             	0x9769eda3 free + 428
5   libmonosgen-2.0.dylib         	0x0036676f monoeg_g_free + 31
6   libmonosgen-2.0.dylib         	0x001f2125 mono_free_method + 133
7   libmonosgen-2.0.dylib         	0x002a1a1c mono_runtime_free_method + 92
8   libmonosgen-2.0.dylib         	0x002d6179 free_dynamic_method + 41
9   libmonosgen-2.0.dylib         	0x0029b98d reference_queue_proccess + 93
10  libmonosgen-2.0.dylib         	0x0029b9e5 reference_queue_proccess_all + 37
11  libmonosgen-2.0.dylib         	0x0029bc37 mono_reference_queue_cleanup + 55
12  libmonosgen-2.0.dylib         	0x0029b4ab mono_gc_cleanup + 267
13  libmonosgen-2.0.dylib         	0x0028af46 mono_runtime_cleanup + 38
14  libmonosgen-2.0.dylib         	0x000ad335 mini_cleanup + 1029
15  libmonosgen-2.0.dylib         	0x00118839 mono_main + 9753
16  com.xamarin.monodevelop       	0x00052817 main + 2503
17  com.xamarin.monodevelop       	0x00050ce5 start + 53

Thread 1:
0   libsystem_kernel.dylib        	0x9214f7d2 mach_msg_trap + 10
1   libsystem_kernel.dylib        	0x9214ecb0 mach_msg + 68
2   libmonosgen-2.0.dylib         	0x00196e8a mach_exception_thread + 90
3   libsystem_c.dylib             	0x97684557 _pthread_start + 344
4   libsystem_c.dylib             	0x9766ecee thread_start + 34

Thread 2:
0   libsystem_kernel.dylib        	0x92151102 __fork + 10
1   libmonosgen-2.0.dylib         	0x00143f94 mono_handle_native_sigsegv + 548
2   libmonosgen-2.0.dylib         	0x00191f65 mono_arch_handle_altstack_exception + 149
3   libmonosgen-2.0.dylib         	0x000af091 mono_sigsegv_signal_handler + 369
4   libsystem_c.dylib             	0x9767086b _sigtramp + 43
5   ???                           	0xffffffff 0 + 4294967295
6   libmonosgen-2.0.dylib         	0x000aef20 mono_sigill_signal_handler + 48
7   libmonosgen-2.0.dylib         	0x002a1a11 mono_runtime_free_method + 81
8   libmonosgen-2.0.dylib         	0x002d6179 free_dynamic_method + 41
9   libmonosgen-2.0.dylib         	0x0029b98d reference_queue_proccess + 93
10  libmonosgen-2.0.dylib         	0x0029b9e5 reference_queue_proccess_all + 37
11  libmonosgen-2.0.dylib         	0x0029b06c finalizer_thread + 636
12  libmonosgen-2.0.dylib         	0x0025cb21 start_wrapper_internal + 769
13  libmonosgen-2.0.dylib         	0x0025cc42 start_wrapper + 34
14  libmonosgen-2.0.dylib         	0x00341dc9 thread_start_routine + 217
15  libmonosgen-2.0.dylib         	0x00360e01 inner_start_thread + 145
16  libsystem_c.dylib             	0x97684557 _pthread_start + 344
17  libsystem_c.dylib             	0x9766ecee thread_start + 34

Thread 3:: Dispatch queue: com.apple.libdispatch-manager
0   libsystem_kernel.dylib        	0x921529ae kevent + 10
1   libdispatch.dylib             	0x93708c71 _dispatch_mgr_invoke + 993
2   libdispatch.dylib             	0x937087a9 _dispatch_mgr_thread + 53

Thread 4:
0   libsystem_kernel.dylib        	0x92151be6 __select + 10
1   libglib-2.0.0.dylib           	0x027a7fbf g_poll + 1295
2   libgdk-quartz-2.0.0.dylib     	0x02e6116c select_thread_func + 332
3   libsystem_c.dylib             	0x97684557 _pthread_start + 344
4   libsystem_c.dylib             	0x9766ecee thread_start + 34

Thread 5:: CVDisplayLink
0   libsystem_kernel.dylib        	0x921518e2 __psynch_cvwait + 10
1   libsystem_c.dylib             	0x97689220 _pthread_cond_wait + 833
2   libsystem_c.dylib             	0x9770f0a1 pthread_cond_wait$UNIX2003 + 71
3   com.apple.CoreVideo           	0x93a1c16d CVDisplayLink::runIOThread() + 903
4   com.apple.CoreVideo           	0x93a1bdce startIOThread(void*) + 160
5   libsystem_c.dylib             	0x97684557 _pthread_start + 344
6   libsystem_c.dylib             	0x9766ecee thread_start + 34

Thread 6:
0   libsystem_kernel.dylib        	0x921520ee __workq_kernreturn + 10
1   libsystem_c.dylib             	0x9768704c _pthread_workq_return + 45
2   libsystem_c.dylib             	0x97686e19 _pthread_wqthread + 448
3   libsystem_c.dylib             	0x9766ecca start_wqthread + 30

Thread 7:
0   libsystem_kernel.dylib        	0x921520ee __workq_kernreturn + 10
1   libsystem_c.dylib             	0x9768704c _pthread_workq_return + 45
2   libsystem_c.dylib             	0x97686e19 _pthread_wqthread + 448
3   libsystem_c.dylib             	0x9766ecca start_wqthread + 30

Thread 8:
0   libsystem_kernel.dylib        	0x921520ee __workq_kernreturn + 10
1   libsystem_c.dylib             	0x9768704c _pthread_workq_return + 45
2   libsystem_c.dylib             	0x97686e19 _pthread_wqthread + 448
3   libsystem_c.dylib             	0x9766ecca start_wqthread + 30

Thread 0 crashed with X86 Thread State (32-bit):
  eax: 0x00000000  ebx: 0x00000007  ecx: 0xbffb06ac  edx: 0x92151a6a
  edi: 0xaca2fa28  esi: 0x00000006  ebp: 0xbffb06c8  esp: 0xbffb06ac
   ss: 0x00000023  efl: 0x00000206  eip: 0x92151a6a   cs: 0x0000000b
   ds: 0x00000023   es: 0x00000023   fs: 0x00000000   gs: 0x0000000f
  cr2: 0x0057000c
Logical CPU: 0
Comment 1 Rodrigo Kumpera 2013-05-23 12:09:37 UTC
Zoltan fixed it.

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