xserver: Branch 'master' - 23 commits

Jeremy Huddleston jeremyhu at apple.com
Fri Dec 9 12:54:36 PST 2011


This introduced a build failure.  disable_clientpointer should return void.

xichangehierarchy.c: In function 'disable_clientpointer':
xichangehierarchy.c:214:1: error: no return statement in function returning non-void [-Werror=return-type]
cc1: some warnings being treated as errors

On Dec 8, 2011, at 21:08, Keith Packard wrote:
> commit d2ebbcdaf6b13d70eee704b1764ff349e1be22a0
> Author: Peter Hutterer <peter.hutterer at who-t.net>
> Date:   Tue Nov 29 16:15:37 2011 +1000
> 
>    Xi: when removing a device, reset ClientPointers where needed
> 
>    if a client had the to-be-removed device as ClientPointer, reset to NULL.
> 
>    Fixes #43165
> 
>    Signed-off-by: Peter Hutterer <peter.hutterer at who-t.net>
>    Reviewed-by: Jeremy Huddleston <jeremyhu at apple.com>
> 
> diff --git a/Xi/xichangehierarchy.c b/Xi/xichangehierarchy.c
> index 614d231..a8bc761 100644
> --- a/Xi/xichangehierarchy.c
> +++ b/Xi/xichangehierarchy.c
> @@ -201,6 +201,19 @@ unwind:
> }
> 
> static int
> +disable_clientpointer(DeviceIntPtr dev)
> +{
> +    int i;
> +
> +    for (i = 0; i < currentMaxClients; i++)
> +    {
> +        ClientPtr client = clients[i];
> +        if (client && client->clientPtr == dev)
> +            client->clientPtr = NULL;
> +    }
> +}
> +
> +static int
> remove_master(ClientPtr client, xXIRemoveMasterInfo *r,
>               int flags[MAXDEVICES])
> {
> @@ -250,6 +263,8 @@ remove_master(ClientPtr client, xXIRemoveMasterInfo *r,
>     if (rc != Success)
>         goto unwind;
> 
> +    disable_clientpointer(ptr);
> +
>     /* Disabling sends the devices floating, reattach them if
>      * desired. */
>     if (r->return_mode == XIAttachToMaster)
> 




More information about the xorg-devel mailing list