[Spice-devel] [spice-server v2 11/14] rcc: Move SpiceDataHeaderOpaque to red-channel-client-private.h

Frediano Ziglio fziglio at redhat.com
Tue Feb 14 15:07:38 UTC 2017


> 
> It's only used by red-channel-client.c
> 
> Signed-off-by: Christophe Fergeau <cfergeau at redhat.com>
> ---
>  server/red-channel-client-private.h | 22 ++++++++++++++++++++++
>  server/red-channel.h                | 22 ----------------------
>  2 files changed, 22 insertions(+), 22 deletions(-)
> 
> diff --git a/server/red-channel-client-private.h
> b/server/red-channel-client-private.h
> index 08ac6ca..5c1308b 100644
> --- a/server/red-channel-client-private.h
> +++ b/server/red-channel-client-private.h
> @@ -21,6 +21,28 @@
>  #include "red-channel.h"
>  #include "red-channel-client.h"
>  
> +typedef struct SpiceDataHeaderOpaque SpiceDataHeaderOpaque;
> +
> +typedef uint16_t (*get_msg_type_proc)(SpiceDataHeaderOpaque *header);
> +typedef uint32_t (*get_msg_size_proc)(SpiceDataHeaderOpaque *header);
> +typedef void (*set_msg_type_proc)(SpiceDataHeaderOpaque *header, uint16_t
> type);
> +typedef void (*set_msg_size_proc)(SpiceDataHeaderOpaque *header, uint32_t
> size);
> +typedef void (*set_msg_serial_proc)(SpiceDataHeaderOpaque *header, uint64_t
> serial);
> +typedef void (*set_msg_sub_list_proc)(SpiceDataHeaderOpaque *header,
> uint32_t sub_list);
> +
> +struct SpiceDataHeaderOpaque {
> +    uint8_t *data;
> +    uint16_t header_size;
> +
> +    set_msg_type_proc set_msg_type;
> +    set_msg_size_proc set_msg_size;
> +    set_msg_serial_proc set_msg_serial;
> +    set_msg_sub_list_proc set_msg_sub_list;
> +
> +    get_msg_type_proc get_msg_type;
> +    get_msg_size_proc get_msg_size;
> +};
> +
>  typedef struct RedChannelClientLatencyMonitor {
>      int state;
>      uint64_t last_pong_time;
> diff --git a/server/red-channel.h b/server/red-channel.h
> index 80910e3..a70e1f7 100644
> --- a/server/red-channel.h
> +++ b/server/red-channel.h
> @@ -37,28 +37,6 @@
>  
>  G_BEGIN_DECLS
>  
> -typedef struct SpiceDataHeaderOpaque SpiceDataHeaderOpaque;
> -
> -typedef uint16_t (*get_msg_type_proc)(SpiceDataHeaderOpaque *header);
> -typedef uint32_t (*get_msg_size_proc)(SpiceDataHeaderOpaque *header);
> -typedef void (*set_msg_type_proc)(SpiceDataHeaderOpaque *header, uint16_t
> type);
> -typedef void (*set_msg_size_proc)(SpiceDataHeaderOpaque *header, uint32_t
> size);
> -typedef void (*set_msg_serial_proc)(SpiceDataHeaderOpaque *header, uint64_t
> serial);
> -typedef void (*set_msg_sub_list_proc)(SpiceDataHeaderOpaque *header,
> uint32_t sub_list);
> -
> -struct SpiceDataHeaderOpaque {
> -    uint8_t *data;
> -    uint16_t header_size;
> -
> -    set_msg_type_proc set_msg_type;
> -    set_msg_size_proc set_msg_size;
> -    set_msg_serial_proc set_msg_serial;
> -    set_msg_sub_list_proc set_msg_sub_list;
> -
> -    get_msg_type_proc get_msg_type;
> -    get_msg_size_proc get_msg_size;
> -};
> -
>  typedef struct RedChannel RedChannel;
>  typedef struct RedChannelClient RedChannelClient;
>  typedef struct RedClient RedClient;

Acked-by: Frediano Ziglio <fziglio at redhat.com>

Frediano


More information about the Spice-devel mailing list