Xlib: Fixes for util/makekeys.
Bernardo Innocenti
bernie at codewiz.org
Mon Jun 11 19:02:56 PDT 2007
Hello,
this is a small workaround for util/makekeys. We triggered this
bug by adding 20 new keys in x11proto/keysymdef.h.
Side note: Josh and Jamey appear to be the current libX11 maintainers
because they released a new version a few days ago. But Keith packard
is the only name listed in the monolithic doc/xorg-docs/MAINTAINERS.
So I suppose the libX11 module could have its own MAINTAINERS file.
>From b58ffc0f9f8c9efd0569a1da3ad2894bd2fff48a Mon Sep 17 00:00:00 2001
From: Bernardo Innocenti <bernie at codewiz.org>
Date: Mon, 11 Jun 2007 06:12:15 -0400
Subject: [PATCH] Enlarge key table size and give a clue instead of just crashing next time.
Organization: One Laptop Per Child
---
src/util/makekeys.c | 7 ++++++-
1 files changed, 6 insertions(+), 1 deletions(-)
diff --git a/src/util/makekeys.c b/src/util/makekeys.c
index 214ea5c..afc3854 100644
--- a/src/util/makekeys.c
+++ b/src/util/makekeys.c
@@ -42,7 +42,7 @@ char *malloc();
typedef unsigned long Signature;
-#define KTNUM 3000
+#define KTNUM 4000
static struct info {
char *name;
@@ -157,6 +157,11 @@ next1: ;
}
z = best_z;
+ if (z == 0) {
+ fprintf(stderr, "makekeys: try increading KTNUM!\n");
+ exit(1);
+ }
+
printf("#ifdef NEEDKTABLE\n");
printf("const unsigned char _XkeyTable[] = {\n");
printf("0,\n");
--
1.5.2
--
// Bernardo Innocenti
\X/ http://www.codewiz.org/
More information about the xorg
mailing list