[Spice-devel] [PATCH 3.4/12] Remove unused parameter from cursor_channel_new()

Frediano Ziglio fziglio at redhat.com
Fri Oct 30 00:27:26 PDT 2015


> 
> From: Marc-André Lureau <marcandre.lureau at gmail.com>
> 
> cursor_channel_new() is only called from one location, and always passes
> FALSE as the value for the 'migrate' paramater. In addition, this
> parameter is not used within the function. Remove it.
> 
> Signed-off-by: Jonathon Jongsma <jjongsma at redhat.com>
> ---
>  server/cursor-channel.c | 2 +-
>  server/cursor-channel.h | 2 +-
>  server/red_worker.c     | 2 +-
>  3 files changed, 3 insertions(+), 3 deletions(-)
> 
> diff --git a/server/cursor-channel.c b/server/cursor-channel.c
> index 219c1da..2ea00c8 100644
> --- a/server/cursor-channel.c
> +++ b/server/cursor-channel.c
> @@ -362,7 +362,7 @@ static void cursor_channel_release_item(RedChannelClient
> *rcc, PipeItem *item, i
>      }
>  }
>  
> -CursorChannel* cursor_channel_new(RedWorker *worker, int migrate)
> +CursorChannel* cursor_channel_new(RedWorker *worker)
>  {
>      CursorChannel* cursor;
>  
> diff --git a/server/cursor-channel.h b/server/cursor-channel.h
> index c7eee81..213f124 100644
> --- a/server/cursor-channel.h
> +++ b/server/cursor-channel.h
> @@ -78,7 +78,7 @@ typedef struct CursorChannel {
>  
>  G_STATIC_ASSERT(sizeof(CursorItem) <= QXL_CURSUR_DEVICE_DATA_SIZE);
>  
> -CursorChannel*       cursor_channel_new         (RedWorker *worker, int
> migrate);
> +CursorChannel*       cursor_channel_new         (RedWorker *worker);
>  void                 cursor_channel_disconnect  (CursorChannel *cursor);
>  void                 cursor_channel_reset       (CursorChannel *cursor);
>  void                 cursor_channel_process_cmd (CursorChannel *cursor,
>  RedCursorCmd *cursor_cmd,
> diff --git a/server/red_worker.c b/server/red_worker.c
> index 9f845e4..7b3eee2 100644
> --- a/server/red_worker.c
> +++ b/server/red_worker.c
> @@ -10629,7 +10629,7 @@ void handle_dev_cursor_channel_create(void *opaque,
> void *payload)
>  
>      // TODO: handle seemless migration. Temp, setting migrate to FALSE
>      if (!worker->cursor_channel) {
> -        worker->cursor_channel = cursor_channel_new(worker, FALSE);
> +        worker->cursor_channel = cursor_channel_new(worker);
>      }
>      red_channel = &worker->cursor_channel->common.base;
>      send_data(worker->channel, &red_channel, sizeof(RedChannel *));

Acked

Frediano


More information about the Spice-devel mailing list