[Spice-devel] [PATCH] server: init all fields on SpiceMsgDisplayStreamCreate

Alon Levy alevy at redhat.com
Wed Aug 17 10:57:26 PDT 2011


On Wed, Aug 17, 2011 at 01:01:01PM +0200, Christophe Fergeau wrote:
> red_display_marshall_stream_start initializes a
> SpiceMsgDisplayStreamCreate structure before marshalling it and
> sending it on the wire. However, it never fills
> SpiceMsgDisplayStreamCreate::stamp which then causes a complaint
> from valgrind. This patch sets this value to 0, it's not used
> by the client so the value shouldn't matter.
> ---
>  server/red_worker.c |    2 ++
>  1 files changed, 2 insertions(+), 0 deletions(-)
> 
> diff --git a/server/red_worker.c b/server/red_worker.c
> index efedc19..5c19c0d 100644
> --- a/server/red_worker.c
> +++ b/server/red_worker.c
> @@ -7718,6 +7718,8 @@ static void red_display_marshall_stream_start(DisplayChannel *display_channel,
>          stream_create.clip.rects = &clip_rects;
>      }
>  
> +    stream_create.stamp = 0;
> +
>      spice_marshall_msg_display_stream_create(base_marshaller, &stream_create);
>  }
>  

ACK. Actually also the previous patch. I can rebase on top I guess, and
it might make sure I notice if the multiclient patchset breaks it or not.

> -- 
> 1.7.6
> 
> _______________________________________________
> Spice-devel mailing list
> Spice-devel at lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/spice-devel


More information about the Spice-devel mailing list