[Spice-devel] [spice-gtk][PATCH 1/4] ppc: Fix glz magic endianess

Christophe Fergeau cfergeau at redhat.com
Mon May 18 09:45:06 PDT 2015


On Mon, May 18, 2015 at 03:11:05PM +0200, Fabiano FidĂȘncio wrote:
> ---
>  gtk/decode-glz.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/gtk/decode-glz.c b/gtk/decode-glz.c
> index 34a7185..f536d31 100644
> --- a/gtk/decode-glz.c
> +++ b/gtk/decode-glz.c
> @@ -344,7 +344,7 @@ static void decode_header(GlibGlzDecoder *d)
>      uint32_t stride;
>      uint8_t tmp;
>  
> -    magic = decode_32(d);
> +    magic = GUINT32_FROM_LE(decode_32(d));

Ah, this has to leak in code using spice-common/spice-protocol. I'm
starting to wonder if we should not change the definition of these
_MAGIC constants so that we don't need to swap stuff around, which is
different from what we do to all other values (eg 'version' below).

Looks good for now though, ACK.

Christophe
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 819 bytes
Desc: not available
URL: <http://lists.freedesktop.org/archives/spice-devel/attachments/20150518/3823b4d9/attachment.sig>


More information about the Spice-devel mailing list