From: Ran Benita Date: Fri, 7 Feb 2014 15:11:49 +0000 (+0200) Subject: x11: add explicit cast in mods conversion X-Git-Tag: xkbcommon-0.4.1~89 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=125bb19ede2582dc489b2728ccb9af3c0f800ddd;p=platform%2Fupstream%2Flibxkbcommon.git x11: add explicit cast in mods conversion Explicit is better and all. Signed-off-by: Ran Benita --- diff --git a/src/x11/keymap.c b/src/x11/keymap.c index 968f187..fa32d16 100644 --- a/src/x11/keymap.c +++ b/src/x11/keymap.c @@ -92,7 +92,10 @@ translate_mods(uint8_t rmods, uint16_t vmods_low, uint16_t vmods_high) { /* We represent mod masks in a single uint32_t value, with real mods * first and vmods after (though we don't make these distinctions). */ - return rmods | (vmods_low << 8) | (vmods_high << 16); + return + ((xkb_mod_mask_t) rmods) | + ((xkb_mod_mask_t) vmods_low << 8) | + ((xkb_mod_mask_t) vmods_high << 16); } static enum xkb_action_controls