[PATCH] Add -xkbcompdir parameter to modify "xkbcomp" path from commandline.
Adam Tkac
atkac at redhat.com
Thu Sep 2 08:40:03 PDT 2010
Hello,
attached patch adds new option "-xkbcompdir" which allows to change
xkbcomp path from commandline, please apply it to both master and
server-1.9-branch branches.
Regards, Adam
--
Adam Tkac, Red Hat, Inc.
-------------- next part --------------
Subject: [PATCH] Add -xkbcompdir parameter to modify "xkbcomp" path from commandline.
Signed-off-by: Adam Tkac <atkac at redhat.com>
---
xkb/xkbInit.c | 13 +++++++++++++
1 files changed, 13 insertions(+), 0 deletions(-)
diff --git a/xkb/xkbInit.c b/xkb/xkbInit.c
index fbf8f14..98e453a 100644
--- a/xkb/xkbInit.c
+++ b/xkb/xkbInit.c
@@ -742,7 +742,20 @@ XkbProcessArguments(int argc,char *argv[],int i)
}
}
return j;
+ } else if (strncmp(argv[i], "-xkbcompdir", 11)==0) {
+ if (++i < argc) {
+ if (strlen(argv[i]) < PATH_MAX) {
+ XkbBinDirectory = argv[i];
+ return 2;
+ } else {
+ LogMessage(X_ERROR, "-xkbcompdir pathname too long\n");
+ return -1;
+ }
+ } else {
+ return -1;
+ }
}
+
if ((strcmp(argv[i], "-ardelay") == 0) ||
(strcmp (argv[i], "-ar1") == 0)) { /* -ardelay int */
if (++i >= argc) UseMsg ();
--
1.7.2.2
More information about the xorg-devel
mailing list