- /* Wait for the thread to actually exit */
- ret = guarded_wait (gc_thread->handle, MONO_INFINITE_WAIT, TRUE);
+ /* Wait for the thread to actually exit. We don't want the wait
+ * to be alertable, because we assert on the result to be SUCCESS_0 */
+ ret = guarded_wait (gc_thread->handle, MONO_INFINITE_WAIT, FALSE);