summaryrefslogtreecommitdiff
path: root/Build/source/texk/lacheck/lacheck-1.26-PATCHES/patch-03-unsigned-char
blob: e5b07bcfee068184d9bedd1dd498761e162fcb31 (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
diff -ur lacheck-1.26.orig/lacheck.l lacheck-1.26/lacheck.l
--- lacheck-1.26.orig/lacheck.l	2010-12-09 23:22:45.000000000 +0100
+++ lacheck-1.26/lacheck.l	2010-12-09 23:25:22.000000000 +0100
@@ -136,7 +136,7 @@
 
   /* macros */
 
-#define CG_NAME (char *)gstack[gstackp-1].s_name
+#define CG_NAME gstack[gstackp-1].s_name
 #define CG_TYPE gstack[gstackp-1].s_type
 #define CG_LINE gstack[gstackp-1].s_line
 #define CG_ITALIC gstack[gstackp-1].italic
@@ -165,7 +165,7 @@
 
 typedef struct tex_group 
  {
-    unsigned char *s_name;
+    char *s_name;
     int s_type;
     int s_line;
     int italic;
@@ -467,7 +467,7 @@
 
 \\begingroup/[^a-zA-Z]  {
  {
-    push((unsigned char *)"\\begingroup", 1, line_count); 
+    push("\\begingroup", 1, line_count); 
  }}
 
 
@@ -858,7 +858,7 @@
 }
 #endif /* NEED_STRSTR */
 
-void push(const unsigned char *p_name, int p_type, int p_line)
+void push(const char *p_name, int p_type, int p_line)
 {
     if ( gstackp == gstack_size ) {	/* extend stack */
 	gstack_size *= 2;
@@ -870,14 +870,14 @@
     }
     
     if ( (gstack[gstackp].s_name =
-		(unsigned char *)malloc(strlen((char *)p_name) + 1)) == NULL ||
+		(char *)malloc(strlen(p_name) + 1)) == NULL ||
          (gstack[gstackp].s_file =
 		(char *)malloc(strlen(file_name) + 1)) == NULL ) {
 	fprintf(stderr, "%s: out of memory\n", PROGNAME);
 	exit(3);
     }
 
-    strcpy((char *)gstack[gstackp].s_name,(char *)p_name);
+    strcpy(gstack[gstackp].s_name, p_name);
     gstack[gstackp].s_type = p_type;
     gstack[gstackp].s_line = p_line;	
     gstack[gstackp].italic = (  (p_type == 4 || p_type == 5)