Skip to content
Permalink
Browse files Browse the repository at this point in the history
xkbcomp: Don't explode on invalid virtual modifiers
testcase: 'virtualModifiers=LevelThreC'

Signed-off-by: Daniel Stone <daniels@collabora.com>
  • Loading branch information
fooishbar committed Aug 3, 2018
1 parent 96df310 commit 4e2ee9c
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/xkbcomp/expr.c
Expand Up @@ -101,6 +101,8 @@ LookupModMask(struct xkb_context *ctx, const void *priv, xkb_atom_t field,
return false;

str = xkb_atom_text(ctx, field);
if (!str)
return false;

if (istreq(str, "all")) {
*val_rtrn = MOD_REAL_MASK_ALL;
Expand Down

1 comment on commit 4e2ee9c

@msmeissn
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please sign in to comment.