action: fix misleading cast
authorRan Benita <ran234@gmail.com>
Sat, 8 Feb 2014 13:06:28 +0000 (15:06 +0200)
committerRan Benita <ran234@gmail.com>
Sat, 8 Feb 2014 13:06:28 +0000 (15:06 +0200)
The type is uint8_t and so is the checked range.

Signed-off-by: Ran Benita <ran234@gmail.com>
src/xkbcomp/action.c

index a1a81888dda025e9db2dbae03d1988ddba11aab9..9a0b5d5af0aaec0e9c0e7814927c430c0fc901c7 100644 (file)
@@ -572,7 +572,7 @@ HandlePtrBtn(struct xkb_keymap *keymap, union xkb_action *action,
             return false;
         }
 
-        act->count = (uint16_t) val;
+        act->count = (uint8_t) val;
         return true;
     }
     return ReportIllegal(keymap, action->type, field);