From 304c030d02aaff375e2641d04fa1ebb577bbea2e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sebastian=20Dr=C3=B6ge?= Date: Fri, 20 Jun 2008 11:29:25 +0000 Subject: [PATCH] Bug 316221 - G_LOCK warns about breaking strict-aliasing rules * configure.in: * glib/gthread.h: Revert previous patch as it doesn't improve the situation and results in other warnings. svn path=/trunk/; revision=7064 --- ChangeLog | 8 ++++++++ configure.in | 6 ------ glib/gthread.h | 6 ------ 3 files changed, 8 insertions(+), 12 deletions(-) diff --git a/ChangeLog b/ChangeLog index cf6742f45..58b581838 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,11 @@ +2008-06-20 Sebastian Dröge + + Bug 316221 - G_LOCK warns about breaking strict-aliasing rules + + * configure.in: + * glib/gthread.h: Revert previous patch as it doesn't improve the + situation and results in other warnings. + 2008-06-16 Christian Persch Bug 539123 – annotate g_d[n]gettext with G_GNUC_FORMAT diff --git a/configure.in b/configure.in index a2b516652..70ac4db83 100644 --- a/configure.in +++ b/configure.in @@ -2844,15 +2844,9 @@ struct _GStaticMutex } static_mutex; }; #define G_STATIC_MUTEX_INIT { NULL, { { $g_mutex_contents} } } -#ifdef __cplusplus #define g_static_mutex_get_mutex(mutex) \\ (g_thread_use_default_impl ? ((GMutex*) ((mutex)->static_mutex.pad)) : \\ g_static_mutex_get_mutex_impl_shortcut (&((mutex)->runtime_mutex))) -#else -#define g_static_mutex_get_mutex(mutex) \\ - (g_thread_use_default_impl ? ((GMutex*) (void*) ((mutex)->static_mutex.pad)) : \\ - g_static_mutex_get_mutex_impl_shortcut (&((mutex)->runtime_mutex))) -#endif _______EOF else cat >>$outfile <<_______EOF diff --git a/glib/gthread.h b/glib/gthread.h index cfa12d042..af1e301eb 100644 --- a/glib/gthread.h +++ b/glib/gthread.h @@ -144,15 +144,9 @@ void g_thread_init_with_errorcheck_mutexes (GThreadFunctions* vtable); /* internal function for fallback static mutex implementation */ GMutex* g_static_mutex_get_mutex_impl (GMutex **mutex); -#ifdef __cplusplus #define g_static_mutex_get_mutex_impl_shortcut(mutex) \ (g_atomic_pointer_get ((gpointer*)(void*)mutex) ? *(mutex) : \ g_static_mutex_get_mutex_impl (mutex)) -#else -#define g_static_mutex_get_mutex_impl_shortcut(mutex) \ - (g_atomic_pointer_get (mutex) ? *(mutex) : \ - g_static_mutex_get_mutex_impl (mutex)) -#endif /* shorthands for conditional and unconditional function calls */