[Swfdec-commits] swfdec/swfdec_as_types.h

Benjamin Otte company at kemper.freedesktop.org
Fri Nov 7 11:44:07 PST 2008


 swfdec/swfdec_as_types.h |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit f7344fc6f41e6b164024ab7f9df5eeff482815f6
Author: Benjamin Otte <otte at gnome.org>
Date:   Fri Nov 7 20:43:02 2008 +0100

    cast SWFDEC_AS_VALUE_GET_TYPE() to SwfdecAsValue
    
    This is necessary to get warnings when using it in a switch or for being
    able to use %u when printf'ing it

diff --git a/swfdec/swfdec_as_types.h b/swfdec/swfdec_as_types.h
index bfa05b0..756e8c1 100644
--- a/swfdec/swfdec_as_types.h
+++ b/swfdec/swfdec_as_types.h
@@ -63,7 +63,7 @@ typedef struct _SwfdecScript SwfdecScript;
 #define SWFDEC_AS_VALUE_TYPE_MASK ((1 << SWFDEC_AS_VALUE_TYPE_BITS) - 1)
 #define SWFDEC_AS_VALUE_VALUE_MASK (~SWFDEC_AS_VALUE_TYPE_MASK)
 
-#define SWFDEC_AS_VALUE_GET_TYPE(val) ((val) & SWFDEC_AS_VALUE_TYPE_MASK)
+#define SWFDEC_AS_VALUE_GET_TYPE(val) ((SwfdecAsValueType) ((val) & SWFDEC_AS_VALUE_TYPE_MASK))
 #define SWFDEC_AS_VALUE_GET_VALUE(val) GSIZE_TO_POINTER ((val) & SWFDEC_AS_VALUE_VALUE_MASK)
 #define SWFDEC_AS_VALUE_COMBINE(val, type) (GPOINTER_TO_SIZE (val) | type)
 


More information about the Swfdec-commits mailing list