glib r6848 - in trunk: . glib



Author: hasselmm
Date: Thu Apr 10 22:40:48 2008
New Revision: 6848
URL: http://svn.gnome.org/viewvc/glib?rev=6848&view=rev

Log:
Bug 519137 â g_slice_dup macro needs cast for 64-bit platform

* glib/gslice.h (g_slice_copy): Apply type casts needed
  for proper compilation on 64-bit platforms.


Modified:
   trunk/ChangeLog
   trunk/glib/gslice.h

Modified: trunk/glib/gslice.h
==============================================================================
--- trunk/glib/gslice.h	(original)
+++ trunk/glib/gslice.h	Thu Apr 10 22:40:48 2008
@@ -59,7 +59,8 @@
 
 /* we go through extra hoops to ensure type safety */
 #define g_slice_dup(type, mem)                                  \
-  (1 ? g_slice_copy (sizeof (type), (mem)) : (type*) ((type*) 0 == (mem)))
+  (1 ? (type*) g_slice_copy (sizeof (type), (mem))              \
+     : ((void) ((type*) 0 == (mem)), (type*) 0))
 #define g_slice_free(type, mem)				do {	\
   if (1) g_slice_free1 (sizeof (type), (mem));			\
   else   (void) ((type*) 0 == (mem)); 				\



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]