[PATCH xinput 1/1] Print usage when run with --help
Bryce Harrington
bryce at canonical.com
Wed Nov 30 04:41:38 PST 2011
On Tue, Nov 29, 2011 at 11:52:53PM -0800, Jeremy Huddleston wrote:
> Signed-off-by: Jeremy Huddleston <jeremyhu at apple.com>
> ---
> src/xinput.c | 5 +++++
> 1 files changed, 5 insertions(+), 0 deletions(-)
>
> diff --git a/src/xinput.c b/src/xinput.c
> index 27fb23e..2d9a893 100644
> --- a/src/xinput.c
> +++ b/src/xinput.c
> @@ -357,6 +357,11 @@ main(int argc, char * argv[])
> return print_version(argv[0]);
> }
>
> + if (strcmp("help", func) == 0) {
> + usage();
> + return 0;
> + }
> +
> display = XOpenDisplay(NULL);
>
> if (display == NULL) {
> --
> 1.7.7
Reviewed-by: Bryce Harrington <bryce at canonical.com>
More information about the xorg-devel
mailing list