[Spice-commits] spice/macros.h

Christophe Fergau teuf at kemper.freedesktop.org
Wed Aug 12 05:17:47 PDT 2015


 spice/macros.h |    4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

New commits:
commit 726c6520aea11e8dc281b903f7253986983731d3
Author: Christophe Fergeau <cfergeau at redhat.com>
Date:   Wed Aug 12 14:17:00 2015 +0200

    Use 0xffu everywhere in new SPICE_MAGIC_CONST macro
    
    This should have been squashed in the commit introducing the macro, but
    I forgot to commit this before pushing it.

diff --git a/spice/macros.h b/spice/macros.h
index 679d68d..716f6e0 100644
--- a/spice/macros.h
+++ b/spice/macros.h
@@ -416,10 +416,10 @@
 
 #if SPICE_ENDIAN == SPICE_ENDIAN_LITTLE
 #define SPICE_MAGIC_CONST(s) \
-    ((uint32_t)((s[0]&0xffu)|((s[1]&0xffu)<<8)|((s[2]&0xff)<<16)|((s[3]&0xffu)<<24)))
+    ((uint32_t)((s[0]&0xffu)|((s[1]&0xffu)<<8)|((s[2]&0xffu)<<16)|((s[3]&0xffu)<<24)))
 #else
 #define SPICE_MAGIC_CONST(s) \
-    ((uint32_t)((s[3]&0xffu)|((s[2]&0xffu)<<8)|((s[1]&0xff)<<16)|((s[0]&0xffu)<<24)))
+    ((uint32_t)((s[3]&0xffu)|((s[2]&0xffu)<<8)|((s[1]&0xffu)<<16)|((s[0]&0xffu)<<24)))
 #endif
 
 #endif /* _H_SPICE_MACROS */


More information about the Spice-commits mailing list