Merge pull request #496 from nicolas-raoul/unit-test-for-issue2907
[mono.git] / mono / mini / mini-darwin.c
index 027b0872049e1df1c0496b23d7c656b1cfe5a899..5ec06d20a748c8036e64b9900bbc623f3a47b723 100644 (file)
@@ -69,7 +69,7 @@
 #include <dlfcn.h>
 #include <AvailabilityMacros.h>
 
-#if (MAC_OS_X_VERSION_MIN_REQUIRED <= MAC_OS_X_VERSION_10_5) && !defined (TARGET_ARM)
+#if defined (TARGET_OSX) && (MAC_OS_X_VERSION_MIN_REQUIRED <= MAC_OS_X_VERSION_10_5)
 #define NEEDS_EXCEPTION_THREAD
 #endif
 
@@ -307,7 +307,7 @@ mono_thread_state_init_from_handle (MonoThreadUnwindState *tctx, MonoNativeThrea
 
        mono_sigctx_to_monoctx (&ctx, &tctx->ctx);
 
-       domain_key = mono_domain_get_tls_offset ();
+       domain_key = mono_domain_get_tls_key ();
        jit_key = mono_get_jit_tls_key ();
 
        jit_tls = mono_mach_arch_get_tls_value_from_thread (thread_id, jit_key);