[Spice-devel] [RFC v4 33/62] server/red_worker: fix red_pipe_remove_drawable
Marc-André Lureau
marcandre.lureau at gmail.com
Mon May 2 16:55:58 PDT 2011
Why did you choose to do it seperately from 29/62?
On Tue, Apr 26, 2011 at 12:54 PM, Alon Levy <alevy at redhat.com> wrote:
> ---
> server/red_worker.c | 11 ++++++-----
> 1 files changed, 6 insertions(+), 5 deletions(-)
>
> diff --git a/server/red_worker.c b/server/red_worker.c
> index 4fbcb4f..a700f7e 100644
> --- a/server/red_worker.c
> +++ b/server/red_worker.c
> @@ -1298,11 +1298,10 @@ static inline PipeItem *red_pipe_get_tail(DisplayChannelClient *dcc)
>
> static inline void red_destroy_surface(RedWorker *worker, Surfaces *surfaces, uint32_t surface_id);
>
> -static inline void red_pipe_remove_drawable(RedWorker *worker, Drawable *drawable)
> +static inline void red_pipe_remove_drawable(DisplayChannelClient *dcc, Drawable *drawable)
> {
> if (pipe_item_is_linked(&drawable->pipe_item)) {
> - red_channel_client_pipe_remove_and_release(
> - worker->display_channel->common.base.rcc, &drawable->pipe_item);
> + red_channel_client_pipe_remove_and_release( &dcc->common.base, &drawable->pipe_item);
> }
> }
>
> @@ -1653,7 +1652,9 @@ static inline void current_remove_drawable(RedWorker *worker, Surfaces *surfaces
>
> static void remove_drawable(RedWorker *worker, Surfaces *surfaces, Drawable *item)
> {
> - red_pipe_remove_drawable(worker, item);
> + if (surfaces->dcc) {
> + red_pipe_remove_drawable(surfaces->dcc, item);
> + }
> current_remove_drawable(worker, surfaces, item);
> }
>
> @@ -6400,7 +6401,7 @@ static void red_pipe_replace_rendered_drawables_with_images(RedWorker *worker,
> num_resent++;
>
> ASSERT(image);
> - red_pipe_remove_drawable(worker, drawable);
> + red_pipe_remove_drawable(dcc, drawable);
> pipe_item = &image->link;
> }
> }
> --
> 1.7.4.4
>
> _______________________________________________
> 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