[PATCH:xserver 2/2] xkb: Fix case checks for Latin 8.

Daniel Stone daniel at fooishbar.org
Fri Jun 3 02:30:50 PDT 2011


On Tue, May 24, 2011 at 01:08:28PM +0200, Cyril Brulebois wrote:
> Spotted by -Wlogical-op:
> |   CC     xkbfmisc.lo
> | xkbfmisc.c: In function '_XkbKSCheckCase':
> | xkbfmisc.c:104:3: warning: logical 'and' of mutually exclusive tests is always false [-Wlogical-op]
> | xkbfmisc.c:118:3: warning: logical 'and' of mutually exclusive tests is always false [-Wlogical-op]
> 
> A quick look at the keysymdef.h file (from xproto) suggests the
> implementor chose to use interval checks to determine the case, but
> since lines weren't sorted by codepoints, checks were quite wrong.
> 
> Implement _XkbKSUpper/_XkbKSLower checks based on a grep for
> CAPITAL/SMALL (respectively) on the Latin 8 part of the said file.
> 
> Signed-off-by: Cyril Brulebois <kibi at debian.org>

Reviewed-by: Daniel Stone <daniel at fooishbar.org>

I think someone noted a case statement would be nicer here, but it's
entirely consistent with the rest of the file, so either is fine by me.

Cheers,
Daniel


More information about the xorg-devel mailing list