posix_check_cmd (pthread_join (*(pthread_t*)thread, &ignore));
}
-static void
-g_thread_exit_posix_impl (void)
+void
+g_system_thread_exit (void)
{
pthread_exit (NULL);
}
g_thread_create_posix_impl,
g_thread_yield,
g_thread_join_posix_impl,
- g_thread_exit_posix_impl,
+ g_system_thread_exit,
g_thread_set_priority_posix_impl,
g_thread_self_posix_impl,
g_system_thread_equal,
*(GThreadData **)thread = self;
}
-static void
-g_thread_exit_win32_impl (void)
+void
+g_system_thread_exit (void)
{
GThreadData *self = TlsGetValue (g_thread_self_tls);
gboolean dtors_called;
self->func (self->data);
- g_thread_exit_win32_impl ();
+ g_system_thread_exit ();
g_assert_not_reached ();
g_thread_create_win32_impl, /* thread */
g_thread_yield,
g_thread_join_win32_impl,
- g_thread_exit_win32_impl,
+ g_system_thread_exit,
g_thread_set_priority_win32_impl,
g_thread_self_win32_impl,
- NULL /* no equal function necessary */
+ g_system_thread_equal
};
void
* of g_thread_join(). If the current thread is not joinable, @retval
* is ignored. Calling
*
- * <informalexample>
- * <programlisting>
+ * |[
* g_thread_exit (retval);
- * </programlisting>
- * </informalexample>
+ * ]|
*
* is equivalent to returning @retval from the function @func, as given
* to g_thread_create().
{
GRealThread* real = (GRealThread*) g_thread_self ();
real->retval = retval;
- G_THREAD_CF (thread_exit, (void)0, ());
+
+ g_system_thread_exit ();
}
/**
G_GNUC_INTERNAL gboolean g_system_thread_equal (gpointer thread1,
gpointer thread2);
+G_GNUC_INTERNAL void g_system_thread_exit (void);
+
/* Is called from gthread/gthread-impl.c */
void g_thread_init_glib (void);