summaryrefslogtreecommitdiffstats
path: root/sys-apps/kbd/files/kbd-1.12-debian.patch
blob: de1e402e7047ced3432e2a4707eef8aa9b25699e (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
diff -urNad /home/wart/Projects/debian/kbd/new/kbd-1.12/src/loadkeys.y kbd-1.12/src/loadkeys.y
--- /home/wart/Projects/debian/kbd/new/kbd-1.12/src/loadkeys.y	2004-01-27 14:25:50.000000000 +0300
+++ kbd-1.12/src/loadkeys.y	2004-01-27 14:37:01.000000000 +0300
@@ -566,7 +566,7 @@
 }
 
 char *dirpath[] = { "", DATADIR "/" KEYMAPDIR "/**", KERNDIR "/", 0 };
-char *suffixes[] = { "", ".map", 0 };
+char *suffixes[] = { "", ".kmap", ".map", 0 };
 extern FILE *findfile(char *fnam, char **dirpath, char **suffixes);
 
 #undef yywrap
diff -urNad /opt/tmp/kbd-1.12/src/loadunimap.c kbd-1.12/src/loadunimap.c
--- /opt/tmp/kbd-1.12/src/loadunimap.c	2004-08-02 22:57:25.000000000 +0200
+++ kbd-1.12/src/loadunimap.c	2004-08-02 22:57:44.000000000 +0200
@@ -28,8 +28,8 @@
 extern char *progname;
 extern int force;
 
-static char *unidirpath[] = { "", DATADIR "/" UNIMAPDIR "/", 0 };
-static char *unisuffixes[] = { "", ".uni", 0 };
+static char *unidirpath[] = { "", DATADIR "/" TRANSDIR "/", 0 };
+static char *unisuffixes[] = { "", ".sfm", ".uni", 0 };
 
 #ifdef MAIN
 #include "version.h"
diff -urNad /opt/tmp/kbd-1.12/src/getunimap.c kbd-1.12/src/getunimap.c
--- /opt/tmp/kbd-1.12/src/getunimap.c	2004-08-01 20:33:38.000000000 +0200
+++ kbd-1.12/src/getunimap.c	2004-08-02 22:45:30.000000000 +0200
@@ -62,7 +62,7 @@
 		}
 	}
 
-	if (argc != 1)
+	if (optind < argc)
 		usage();
 
 	fd = getfd(console);
diff -urNad /opt/tmp/kbd-1.12/src/loadunimap.c kbd-1.12/src/loadunimap.c
--- /opt/tmp/kbd-1.12/src/loadunimap.c	2004-08-02 22:45:06.000000000 +0200
+++ kbd-1.12/src/loadunimap.c	2004-08-02 22:46:39.000000000 +0200
@@ -73,18 +73,18 @@
 		}
 	}
 
-	if (argc > 2 || (argc == 1 && !outfnam))
+	if (argc > optind+1 || (argc == optind && !outfnam))
 		usage();
 
 	fd = getfd(console);
 
 	if (outfnam) {
 		saveunicodemap(fd, outfnam);
-		if (argc == 1)
+		if (argc == optind)
 			exit(0);
 	}
 
-	if (argc == 2)
+	if (argc == optind+1)
 		infnam = argv[optind];
 	loadunicodemap(fd, infnam);
 	exit(0);
diff -urNad /opt/tmp/kbd-1.12/src/showconsolefont.c kbd-1.12/src/showconsolefont.c
--- /opt/tmp/kbd-1.12/src/showconsolefont.c	2004-08-02 22:44:30.000000000 +0200
+++ kbd-1.12/src/showconsolefont.c	2004-08-02 22:47:07.000000000 +0200
@@ -135,7 +135,7 @@
 		}
 	}
 
-	if (argc != 1)
+	if (optind < argc)
 		usage();
 
 	fd = getfd(console);
--- kbd-1.12.orig/src/kbdrate.c
+++ kbd-1.12/src/kbdrate.c
@@ -112,7 +112,7 @@
 	kbdrep_s.period = -1;
 	kbdrep_s.delay = -1;
 	if (ioctl( 0, KDKBDREP, &kbdrep_s )) {
-		if (errno == EINVAL)
+		if (errno == EINVAL || errno == ENOTTY)
 			return 0;
 		perror( "ioctl(KDKBDREP)" );
 		exit( 1 );