[Spice-devel] [PATCH] demarshall: add missing parens in BE read_xxx functions
Marc-André Lureau
marcandre.lureau at gmail.com
Fri Apr 6 06:37:23 PDT 2012
ack
On Fri, Apr 6, 2012 at 3:33 PM, Christophe Fergeau <cfergeau at redhat.com> wrote:
> The missing parens causes build to fail on big-endian machines
> ---
> python_modules/demarshal.py | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/python_modules/demarshal.py b/python_modules/demarshal.py
> index c8c6837..cf48d74 100644
> --- a/python_modules/demarshal.py
> +++ b/python_modules/demarshal.py
> @@ -50,7 +50,7 @@ def write_parser_helpers(writer):
> writer.macro("read_%s" % type, "ptr", "(*((%s_t *)(ptr)))" % type)
> writer.macro("write_%s" % type, "ptr, val", "*(%s_t *)(ptr) = val" % (type))
> else:
> - writer.macro("read_%s" % type, "ptr", "((%s_t)%s(*((%s_t *)(ptr)))" % (type, swap, utype))
> + writer.macro("read_%s" % type, "ptr", "((%s_t)%s(*((%s_t *)(ptr))))" % (type, swap, utype))
> writer.macro("write_%s" % type, "ptr, val", "*(%s_t *)(ptr) = %s((%s_t)val)" % (utype, swap, utype))
> writer.writeln("#else")
> for size in [8, 16, 32, 64]:
> --
> 1.7.9.3
>
> _______________________________________________
> Spice-devel mailing list
> Spice-devel at lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/spice-devel
--
Marc-André Lureau
More information about the Spice-devel
mailing list