2 * mono-threads-windows-abort-syscall.c: Low-level syscall aborting
5 * Ludovic Henry (ludovic@xamarin.com)
7 * (C) 2015 Xamarin, Inc
13 #include <mono/utils/mono-threads.h>
15 #if defined(USE_WINDOWS_BACKEND)
20 mono_threads_abort_syscall_init (void)
25 abort_apc (ULONG_PTR param)
30 mono_threads_suspend_abort_syscall (MonoThreadInfo *info)
32 DWORD id = mono_thread_info_get_tid (info);
35 handle = OpenThread (THREAD_ALL_ACCESS, FALSE, id);
38 QueueUserAPC ((PAPCFUNC)abort_apc, handle, (ULONG_PTR)NULL);
44 mono_threads_suspend_needs_abort_syscall (void)