Merge pull request #1088 from BrzVlad/pushless
[mono.git] / mono / mini / mini-gc.c
index 41ca382a0bce51e8d0fe140f32ea6ea2fe8ec1c6..1566cb0d8741a3473f18e0329270b1c4bb7c6bd4 100644 (file)
@@ -598,13 +598,15 @@ thread_suspend_func (gpointer user_data, void *sigctx, MonoContext *ctx)
 
        if (tls->tid != GetCurrentThreadId ()) {
                /* Happens on osx because threads are not suspended using signals */
+#ifndef TARGET_WIN32
                gboolean res;
+#endif
 
                g_assert (tls->info);
 #ifdef TARGET_WIN32
                return;
 #else
-               res = mono_thread_state_init_from_handle (&tls->unwind_state, (MonoNativeThreadId)tls->tid, tls->info->native_handle);
+               res = mono_thread_state_init_from_handle (&tls->unwind_state, tls->info);
 #endif
        } else {
                tls->unwind_state.unwind_data [MONO_UNWIND_DATA_LMF] = mono_get_lmf ();