[Spice-devel] [PATCH spice-server] Avoid to typedef twice MainChannel

Jonathon Jongsma jjongsma at redhat.com
Thu Oct 20 15:56:19 UTC 2016


Acked-by: Jonathon Jongsma <jjongsma at redhat.com>


On Thu, 2016-10-20 at 13:04 +0100, Frediano Ziglio wrote:
> MainChannel is already defined in main-channel.h.
> 
> Signed-off-by: Frediano Ziglio <fziglio at redhat.com>
> ---
>  server/main-channel-client.h | 4 +---
>  server/main-channel.h        | 1 -
>  2 files changed, 1 insertion(+), 4 deletions(-)
> 
> This is a stripped down version of another RHEL 6
> patch without removing typedef in the "right" file.
> 
> diff --git a/server/main-channel-client.h b/server/main-channel-
> client.h
> index 360c61e..14fb419 100644
> --- a/server/main-channel-client.h
> +++ b/server/main-channel-client.h
> @@ -21,12 +21,10 @@
>  #include <common/messages.h>
>  
>  #include "red-channel-client.h"
> +#include "main-channel.h"
>  
>  G_BEGIN_DECLS
>  
> -/* FIXME: remove extra MainChannel typedef when possible */
> -typedef struct MainChannel MainChannel;
> -
>  #define TYPE_MAIN_CHANNEL_CLIENT main_channel_client_get_type()
>  
>  #define MAIN_CHANNEL_CLIENT(obj) \
> diff --git a/server/main-channel.h b/server/main-channel.h
> index 73c8a94..6e89f14 100644
> --- a/server/main-channel.h
> +++ b/server/main-channel.h
> @@ -23,7 +23,6 @@
>  #include <common/marshaller.h>
>  
>  #include "red-channel.h"
> -#include "main-channel-client.h"
>  
>  #define MAIN_CHANNEL(channel) ((MainChannel*)(channel))
>  


More information about the Spice-devel mailing list