Blame SOURCES/0003-xkbcomp-Don-t-explode-on-invalid-virtual-modifiers.patch

a2d0a1
From 55f9df15b30deb0477b8dbcb837f525773705273 Mon Sep 17 00:00:00 2001
a2d0a1
From: Daniel Stone <daniels@collabora.com>
a2d0a1
Date: Mon, 26 Jun 2017 17:18:16 +0100
a2d0a1
Subject: [PATCH 03/10] xkbcomp: Don't explode on invalid virtual modifiers
a2d0a1
a2d0a1
testcase: 'virtualModifiers=LevelThreC'
a2d0a1
a2d0a1
Signed-off-by: Daniel Stone <daniels@collabora.com>
a2d0a1
(cherry picked from commit 4e2ee9c3f6050d773f8bbe05bc0edb17f1ff8371)
a2d0a1
---
a2d0a1
 src/xkbcomp/expr.c | 2 ++
a2d0a1
 1 file changed, 2 insertions(+)
a2d0a1
a2d0a1
diff --git a/src/xkbcomp/expr.c b/src/xkbcomp/expr.c
a2d0a1
index a85f460..d5dd62f 100644
a2d0a1
--- a/src/xkbcomp/expr.c
a2d0a1
+++ b/src/xkbcomp/expr.c
a2d0a1
@@ -101,6 +101,8 @@ LookupModMask(struct xkb_context *ctx, const void *priv, xkb_atom_t field,
a2d0a1
         return false;
a2d0a1
a2d0a1
     str = xkb_atom_text(ctx, field);
a2d0a1
+    if (!str)
a2d0a1
+        return false;
a2d0a1
a2d0a1
     if (istreq(str, "all")) {
a2d0a1
         *val_rtrn  = MOD_REAL_MASK_ALL;
a2d0a1
--
a2d0a1
2.20.1