diff options
Diffstat (limited to 'nx-X11/programs/Xserver/xkb/xkbUtils.c')
-rw-r--r-- | nx-X11/programs/Xserver/xkb/xkbUtils.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/nx-X11/programs/Xserver/xkb/xkbUtils.c b/nx-X11/programs/Xserver/xkb/xkbUtils.c index f4b7db3c6..4adcc878d 100644 --- a/nx-X11/programs/Xserver/xkb/xkbUtils.c +++ b/nx-X11/programs/Xserver/xkb/xkbUtils.c @@ -674,6 +674,9 @@ CARD16 grp_mask; XkbStatePtr state= &xkbi->state; XkbCompatMapPtr map; + if (!state || !xkbi->desc || !xkbi->desc->ctrls || !xkbi->desc->compat) + return; + map= xkbi->desc->compat; grp_mask= map->groups[state->group].mask; state->compat_state = state->mods|grp_mask; @@ -733,6 +736,9 @@ XkbStatePtr state= &xkbi->state; XkbControlsPtr ctrls= xkbi->desc->ctrls; unsigned char grp; + if (!state || !ctrls) + return; + state->mods= (state->base_mods|state->latched_mods); state->mods|= state->locked_mods; state->lookup_mods= state->mods&(~ctrls->internal.mask); |