summaryrefslogtreecommitdiff
path: root/recipes/glib-2.0/glib-2.0-2.24.0/gatomic-proper-pointer-get-cast.patch
blob: 5e8f836cb212b17fd8f0ec76a891a647f167ff99 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
Index: glib-2.23.6/glib/gatomic.h
===================================================================
--- glib-2.23.6.orig/glib/gatomic.h	2010-03-29 13:01:28.000000000 +0400
+++ glib-2.23.6/glib/gatomic.h	2010-03-29 13:01:35.000000000 +0400
@@ -70,7 +70,7 @@
   (g_atomic_int_set) ((volatile gint G_GNUC_MAY_ALIAS *) (void *) (atomic), (newval)))
 # define g_atomic_pointer_get(atomic) \
  ((void) sizeof (gchar [sizeof (*(atomic)) == sizeof (gpointer) ? 1 : -1]), \
-  (g_atomic_pointer_get) ((volatile gpointer G_GNUC_MAY_ALIAS *) (void *) (atomic)))
+  (g_atomic_pointer_get) ((volatile gpointer G_GNUC_MAY_ALIAS *) (volatile void G_GNUC_MAY_ALIAS *) (atomic)))
 # define g_atomic_pointer_set(atomic, newval) \
  ((void) sizeof (gchar [sizeof (*(atomic)) == sizeof (gpointer) ? 1 : -1]), \
   (g_atomic_pointer_set) ((volatile gpointer G_GNUC_MAY_ALIAS *) (void *) (atomic), (newval)))