diff options
author | Ran Benita <ran234@gmail.com> | 2013-07-18 14:50:21 +0300 |
---|---|---|
committer | Ran Benita <ran234@gmail.com> | 2013-07-18 14:50:21 +0300 |
commit | 4b560287f8c88526da59946e99f7919a94dff16a (patch) | |
tree | 13b18fc2a6ff0ec43bc84e75c9807650e377715a /src/xkbcomp/compat.c | |
parent | 6bb727b2275b2715f15b5da4431dee12dcfc7e7c (diff) | |
download | libxkbcommon-4b560287f8c88526da59946e99f7919a94dff16a.tar.gz libxkbcommon-4b560287f8c88526da59946e99f7919a94dff16a.tar.bz2 libxkbcommon-4b560287f8c88526da59946e99f7919a94dff16a.zip |
xkbcomp: escape the section names before storing them in the keymap
This ensures the names are escaped before having any interaction with
the user.
This was caught by noticing dump(compile(dump())) != dump. Since that's
a nice test we add it to stringcomp.
https://bugs.freedesktop.org/show_bug.cgi?id=67032
Reported-By: Auke Booij
Signed-off-by: Ran Benita <ran234@gmail.com>
Diffstat (limited to 'src/xkbcomp/compat.c')
-rw-r--r-- | src/xkbcomp/compat.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/src/xkbcomp/compat.c b/src/xkbcomp/compat.c index 5682895..3a14dc6 100644 --- a/src/xkbcomp/compat.c +++ b/src/xkbcomp/compat.c @@ -1025,6 +1025,7 @@ static bool CopyCompatToKeymap(struct xkb_keymap *keymap, CompatInfo *info) { keymap->compat_section_name = strdup_safe(info->name); + XkbEscapeMapName(keymap->compat_section_name); if (!darray_empty(info->interps)) { /* Most specific to least specific. */ |