[Spice-devel] [PATCH] server/red_worker: fix used but uninitialized warning (gcc 4.6.0)

Uri Lublin uril at redhat.com
Tue Feb 8 10:02:51 PST 2011


On 02/07/2011 03:11 PM, Alon Levy wrote:
> ---
>   server/red_worker.c |    2 +-
>   1 files changed, 1 insertions(+), 1 deletions(-)
>
> diff --git a/server/red_worker.c b/server/red_worker.c
> index f899ff2..f163a71 100644
> --- a/server/red_worker.c
> +++ b/server/red_worker.c
> @@ -6219,7 +6219,7 @@ static inline int drawable_depends_on_areas(Drawable *drawable,
>       int i;
>       RedDrawable *red_drawable;
>       int drawable_has_shadow;
> -    SpiceRect shadow_rect;
> +    SpiceRect shadow_rect = {0, 0, 0, 0};
>
>       red_drawable = drawable->red_drawable;
>       drawable_has_shadow = has_shadow(red_drawable);

OK.
Just a note, this does not fix spice code, but is only needed due to gcc 4.6.0 
imperfection.


More information about the Spice-devel mailing list