summaryrefslogtreecommitdiff
path: root/hw/xfree86/common/xf86Config.c
diff options
context:
space:
mode:
authorPeter Hutterer <peter.hutterer@who-t.net>2014-01-29 11:16:51 +1000
committerPeter Hutterer <peter.hutterer@who-t.net>2014-02-04 10:53:59 +1000
commit2fc38d1e299587d25ca8225051e0ea9403164b15 (patch)
tree7b5dcf7a2d6b54bd3ad5e2e97456b153bde9a587 /hw/xfree86/common/xf86Config.c
parent6307d60dd592f4b438f880d02bde9fd8d50ae264 (diff)
xkb: add a call to init an XkbRMLVOSet from const chars
Just forcing everything to const char* is not helpful, compiler warnings are supposed to warn about broken code. Forcing everything to const when it clearly isn't less than ideal. Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net> Reviewed-by: Hans de Goede <hdegoede@redhat.com>
Diffstat (limited to 'hw/xfree86/common/xf86Config.c')
-rw-r--r--hw/xfree86/common/xf86Config.c16
1 files changed, 8 insertions, 8 deletions
diff --git a/hw/xfree86/common/xf86Config.c b/hw/xfree86/common/xf86Config.c
index 258b22bfe..542d5abf6 100644
--- a/hw/xfree86/common/xf86Config.c
+++ b/hw/xfree86/common/xf86Config.c
@@ -777,13 +777,7 @@ configServerFlags(XF86ConfFlagsPtr flagsconf, XF86OptionPtr layoutopts)
MessageType from;
const char *s;
XkbRMLVOSet set;
-
- /* Default options. */
- set.rules = "base";
- set.model = "pc105";
- set.layout = "us";
- set.variant = NULL;
- set.options = NULL;
+ const char *rules;
/*
* Merge the ServerLayout and ServerFlags options. The former have
@@ -963,9 +957,15 @@ configServerFlags(XF86ConfFlagsPtr flagsconf, XF86OptionPtr layoutopts)
* evdev rules set. */
#if defined(linux)
if (!xf86Info.forceInputDevices)
- set.rules = "evdev";
+ rules = "evdev";
+ else
#endif
+ rules = "base";
+
+ /* Xkb default options. */
+ XkbInitRules(&set, rules, "pc105", "us", NULL, NULL);
XkbSetRulesDflts(&set);
+ XkbFreeRMLVOSet(&set, FALSE);
xf86Info.useDefaultFontPath = TRUE;
xf86Info.useDefaultFontPathFrom = X_DEFAULT;