[Spice-devel] [PATCH] server: fix segfault on client disconnect

Uri Lublin uril at redhat.com
Sun Feb 26 05:25:56 PST 2012


On 02/26/2012 02:34 PM, Alon Levy wrote:
> ..as a result of missing initialization of newly introduced
> pre_disconnect in main channel.
> ---
>  server/main_channel.c |    3 +--
>  1 files changed, 1 insertions(+), 2 deletions(-)
>
> diff --git a/server/main_channel.c b/server/main_channel.c
> index 4d1f8ea..878f62d 100644
> --- a/server/main_channel.c
> +++ b/server/main_channel.c
> @@ -997,8 +997,7 @@ uint64_t main_channel_client_get_bitrate_per_sec(MainChannelClient *mcc)
>  MainChannel* main_channel_init(void)
>  {
>      RedChannel *channel;
> -    ChannelCbs channel_cbs;
> -
> +    ChannelCbs channel_cbs = {0,};
>  
>      channel_cbs.config_socket = main_channel_config_socket;
>      channel_cbs.on_disconnect = main_channel_client_on_disconnect;

Ack.



More information about the Spice-devel mailing list