Re: [PATCH 09/15] Change reds_find_channel() to take RedsState arg

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



> 
> From: Jonathon Jongsma <jjongsma@xxxxxxxxxx>
> 
> ---
>  server/reds.c | 8 ++++----
>  1 file changed, 4 insertions(+), 4 deletions(-)
> 
> diff --git a/server/reds.c b/server/reds.c
> index c3df9df..ffc9d4e 100644
> --- a/server/reds.c
> +++ b/server/reds.c
> @@ -393,7 +393,7 @@ void reds_unregister_channel(RedsState *reds, RedChannel
> *channel)
>      }
>  }
>  
> -static RedChannel *reds_find_channel(uint32_t type, uint32_t id)
> +static RedChannel *reds_find_channel(RedsState *reds, uint32_t type,
> uint32_t id)
>  {
>      RingItem *now;
>  
> @@ -1422,7 +1422,7 @@ static int reds_send_link_ack(RedLinkInfo *link)
>  
>      ack.error = GUINT32_TO_LE(SPICE_LINK_ERR_OK);
>  
> -    channel = reds_find_channel(link->link_mess->channel_type,
> +    channel = reds_find_channel(reds, link->link_mess->channel_type,
>                                  link->link_mess->channel_id);
>      if (!channel) {
>          if (link->link_mess->channel_type != SPICE_CHANNEL_MAIN) {
> @@ -1804,7 +1804,7 @@ static int reds_link_mig_target_channels(RedClient
> *client)
>          RedChannel *channel;
>  
>          mig_link = SPICE_CONTAINEROF(item, RedsMigPendingLink, ring_link);
> -        channel = reds_find_channel(mig_link->link_msg->channel_type,
> +        channel = reds_find_channel(reds, mig_link->link_msg->channel_type,
>                                      mig_link->link_msg->channel_id);
>          if (!channel) {
>              spice_warning("client %p channel (%d, %d) (type, id) wasn't
>              found",
> @@ -1885,7 +1885,7 @@ static void reds_handle_other_links(RedLinkInfo *link)
>      }
>  
>      // TODO: MC: be less lenient. Tally connections from same connection_id
>      (by same client).
> -    if (!(channel = reds_find_channel(link_mess->channel_type,
> +    if (!(channel = reds_find_channel(reds, link_mess->channel_type,
>                                        link_mess->channel_id))) {
>          reds_send_link_result(link, SPICE_LINK_ERR_CHANNEL_NOT_AVAILABLE);
>          reds_link_free(link);

Acked-by: Frediano Ziglio <fziglio@xxxxxxxxxx>

Frediano
_______________________________________________
Spice-devel mailing list
Spice-devel@xxxxxxxxxxxxxxxxxxxxx
http://lists.freedesktop.org/mailman/listinfo/spice-devel




[Index of Archives]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Security]     [Bugtraq]     [Linux]     [Linux OMAP]     [Linux MIPS]     [ECOS]     [Asterisk Internet PBX]     [Linux API]     [Monitors]