Bug 28181

Summary: * Assertion: should not be reached at debugger-agent.c:5957
Product: [Mono] Runtime Reporter: Marek Safar <masafa>
Component: DebuggerAssignee: Zoltan Varga <vargaz>
Status: RESOLVED FIXED    
Severity: normal CC: mono-bugs+mono, mono-bugs+runtime
Priority: ---    
Version: unspecified   
Target Milestone: ---   
Hardware: PC   
OS: Mac OS   
Tags: Is this bug a regression?: ---
Last known good build:

Description Marek Safar 2015-03-19 03:49:32 UTC
using System;
using System.Reflection;

namespace console88
{
	class MainClass
	{
		struct TestFields
		{
			public int MaxValue;
		}

		public static void Main (string[] args)
		{
			TestFields fields = new TestFields { MaxValue = 1234 };
			FieldInfo info = fields.GetType ().GetField ("MaxValue");

			TypedReference reference = __makeref(fields);
			info.SetValueDirect (reference, 4096); // Set a breakpoint here and wait for the crash

			return;
		}

	}
}

* Assertion: should not be reached at debugger-agent.c:5957

Stacktrace:


Native stacktrace:

	0   mono                                0x0016e3c4 mono_handle_native_sigsegv + 452
	1   mono                                0x002238d8 sigabrt_signal_handler + 184
	2   libsystem_platform.dylib            0x91d0d03b _sigtramp + 43
	3   ???                                 0xffffffff 0x0 + 4294967295
	4   libsystem_c.dylib                   0x91cc7eee abort + 156
	5   mono                                0x0045c7f6 monoeg_log_default_handler + 246
	6   mono                                0x0045c6eb monoeg_g_logv + 155
	7   mono                                0x0045c897 monoeg_assertion_message + 71
	8   mono                                0x001a7736 buffer_add_value_full + 2070
	9   mono                                0x001b14a5 add_var + 469
	10  mono                                0x001afb6e frame_commands + 1742
	11  mono                                0x001aa615 debugger_thread + 2501
	12  mono                                0x00451128 inner_start_thread + 632
	13  libsystem_pthread.dylib             0x96466e13 _pthread_body + 138
	14  libsystem_pthread.dylib             0x96466d89 _pthread_body + 0
	15  libsystem_pthread.dylib             0x96464e52 thread_start + 34
Comment 1 Zoltan Varga 2015-03-19 19:33:38 UTC
Fixed in master.