[prev in list] [next in list] [prev in thread] [next in thread] 

List:       freedesktop-xorg-devel
Subject:    Re: [PATCH libXt] remove strcmp
From:       Mark Kettenis <mark.kettenis () xs4all ! nl>
Date:       2010-10-31 17:28:38
Message-ID: 201010311728.o9VHScpa010547 () glazunov ! sibelius ! xs4all ! nl
[Download RAW message or body]

> Date: Tue, 26 Oct 2010 13:48:53 +0200
> From: walter harms <wharms@bfs.de>
> 
> make remainder check like in the rest of code and replace strcmp()

Please try to keep the coding style similar to what's used for the
surrounding code.

>  src/ResConfig.c |    2 +-
>  1 files changed, 1 insertions(+), 1 deletions(-)
> 
> diff --git a/src/ResConfig.c b/src/ResConfig.c
> index 7514754..eb2e7cc 100644
> --- a/src/ResConfig.c
> +++ b/src/ResConfig.c
> @@ -746,7 +746,7 @@ _search_widget_tree (
>  	/*
>  	 * this case covers resources of only one level (eg. *background)
>  	 */
> -	if (strcmp (remainder, "") == 0) {
> +	if ( remainder[0] == 0 ) {
>  		_set_resource_values (w, resource, value, last_part);
>  		if (last_token == '*')
>  			_apply_values_to_children (parent, remainder, resource,
> -- 
> 1.6.0.2
> 
> _______________________________________________
> xorg-devel@lists.x.org: X.Org development
> Archives: http://lists.x.org/archives/xorg-devel
> Info: http://lists.x.org/mailman/listinfo/xorg-devel
> 
_______________________________________________
xorg-devel@lists.x.org: X.Org development
Archives: http://lists.x.org/archives/xorg-devel
Info: http://lists.x.org/mailman/listinfo/xorg-devel
[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic