diff options
author | marha <marha@users.sourceforge.net> | 2012-06-04 09:40:31 +0200 |
---|---|---|
committer | marha <marha@users.sourceforge.net> | 2012-06-04 09:40:31 +0200 |
commit | 63918271b55923e417b14b9e7add4443582cfab3 (patch) | |
tree | 59fc1c26991bbdb97d306da11408e98f49e05607 /xorg-server/xkb | |
parent | 7d6bc8457187e6c4284201b3a6625357c4aca9b4 (diff) | |
parent | 1af6fc1b5d93e54d6674de8b5870448b29f139a7 (diff) | |
download | vcxsrv-63918271b55923e417b14b9e7add4443582cfab3.tar.gz vcxsrv-63918271b55923e417b14b9e7add4443582cfab3.tar.bz2 vcxsrv-63918271b55923e417b14b9e7add4443582cfab3.zip |
Merge remote-tracking branch 'origin/released'
Diffstat (limited to 'xorg-server/xkb')
-rw-r--r-- | xorg-server/xkb/XKBMAlloc.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/xorg-server/xkb/XKBMAlloc.c b/xorg-server/xkb/XKBMAlloc.c index 645e90544..3ffd5dad1 100644 --- a/xorg-server/xkb/XKBMAlloc.c +++ b/xorg-server/xkb/XKBMAlloc.c @@ -375,8 +375,10 @@ XkbResizeKeyType(XkbDescPtr xkb, nResize = 0; for (nTotal = 1, i = xkb->min_key_code; i <= xkb->max_key_code; i++) { width = XkbKeyGroupsWidth(xkb, i); - if (width < type->num_levels) + if (width < type->num_levels || width >= new_num_lvls) { + nTotal += XkbKeyNumSyms(xkb,i); continue; + } for (match = 0, g = XkbKeyNumGroups(xkb, i) - 1; (g >= 0) && (!match); g--) { if (XkbKeyKeyTypeIndex(xkb, i, g) == type_ndx) { @@ -384,7 +386,7 @@ XkbResizeKeyType(XkbDescPtr xkb, match = 1; } } - if ((!match) || (width >= new_num_lvls)) + if (!match) nTotal += XkbKeyNumSyms(xkb, i); else { nTotal += XkbKeyNumGroups(xkb, i) * new_num_lvls; |