[PATCH] Don't clobber input device options from xorg.conf

Peter Hutterer peter.hutterer at who-t.net
Sun Feb 27 15:48:58 PST 2011


On Sun, Feb 27, 2011 at 08:16:03PM +0100, Matthieu Herrb wrote:
> Since commit b8d9c5ff removed commonOptions, we now
> need to append the "Core{Keyboard,Pointer}" options to
> the existing list.
> 
> Fixes passing options to devices confirured in xorg.conf
> on systems where autoaddevices is false.
> 
> Signed-off-by: Matthieu Herrb <matthieu.herrb at laas.fr>
> ---
>  hw/xfree86/common/xf86Config.c |    6 ++++--
>  1 files changed, 4 insertions(+), 2 deletions(-)
> 
> diff --git a/hw/xfree86/common/xf86Config.c b/hw/xfree86/common/xf86Config.c
> index 382700f..6446668 100644
> --- a/hw/xfree86/common/xf86Config.c
> +++ b/hw/xfree86/common/xf86Config.c
> @@ -1224,7 +1224,8 @@ checkCoreInputDevices(serverLayoutPtr servlayoutp, Bool implicitLayout)
>              devs[count - 1] = xnfalloc(sizeof(InputInfoRec));
>  	    *devs[count - 1] = Pointer;
>  	    devs[count - 1]->options =
> -				xf86addNewOption(NULL, xnfstrdup("CorePointer"), NULL);
> +				xf86addNewOption(devs[count -1]->options, 
> +				    xnfstrdup("CorePointer"), NULL);
>  	    devs[count] = NULL;
>  	    servlayoutp->inputs = devs;
>  	}
> @@ -1364,7 +1365,8 @@ checkCoreInputDevices(serverLayoutPtr servlayoutp, Bool implicitLayout)
>              devs[count - 1] = xnfalloc(sizeof(InputInfoRec));
>  	    *devs[count - 1] = Keyboard;
>  	    devs[count - 1]->options =
> -				xf86addNewOption(NULL, xnfstrdup("CoreKeyboard"), NULL);
> +				xf86addNewOption(devs[count - 1]->options, 
> +				    xnfstrdup("CoreKeyboard"), NULL);
>  	    devs[count] = NULL;
>  	    servlayoutp->inputs = devs;
>  	}
> -- 
> 1.7.3.5
 
merged, thanks.

Cheers,
  Peter


More information about the xorg-devel mailing list