summaryrefslogtreecommitdiffstats
path: root/dev-util/biew/files/biew-562-lvalue-casts.patch
blob: d3ade95a8cb81b6b87541491b19cead0ac7d18e7 (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
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
diff -Naurp biew-562-orig/biewlib/file_ini.c biew-562/biewlib/file_ini.c
--- biew-562-orig/biewlib/file_ini.c	2006-08-12 21:56:49.000000000 +0200
+++ biew-562/biewlib/file_ini.c	2006-08-13 12:01:32.000000000 +0200
@@ -1295,7 +1295,7 @@ static tBool __NEAR__ __FASTCALL__ __add
   void __HUGE__ *found;
   ini_cache __HUGE__ *it;
   ini_cache ic;
-  (const char *)ic.item = section;
+  ic.item = section;
   ic.flags = 0;
   if(!(found =la_Find((linearArray *)opening->cache,&ic,__full_compare_cache)))
   {
@@ -1325,7 +1325,7 @@ static tBool __NEAR__ __FASTCALL__ __add
   {
     do_subsect:
       it = (ini_cache __HUGE__ *)found;
-      (const char *)ic.item = subsection;
+      ic.item = subsection;
       if(!(found=la_Find(it->v.leaf,&ic,__full_compare_cache)))
       {
         ic.item = PMalloc(strlen(subsection)+1);
@@ -1354,7 +1354,7 @@ static tBool __NEAR__ __FASTCALL__ __add
       {
         do_item:
         it = (ini_cache __HUGE__ *)found;
-        (const char *)ic.item = item;
+        ic.item = item;
         ic.flags = IC_STRING;
         if(!(found=la_Find(it->v.leaf,&ic,__full_compare_cache)))
         {
@@ -1589,15 +1589,15 @@ unsigned __FASTCALL__ iniReadProfileStri
           ini_cache ic;
           void __HUGE__ *found,__HUGE__ *foundi,__HUGE__ *foundv;
           ini_cache __HUGE__ *fi;
-          (const char *)ic.item = section;
+          ic.item = section;
           ic.flags = 0;
           if((found=la_Find(ini->cache,&ic,__full_compare_cache))!=NULL)
           {
-            (const char *)ic.item=subsection;
+            ic.item=subsection;
             fi = (ini_cache __HUGE__ *)found;
             if((foundi=la_Find(fi->v.leaf,&ic,__full_compare_cache))!=NULL)
             {
-               (const char *)ic.item = _item;
+               ic.item = _item;
                ic.flags = IC_STRING;
                fi = (ini_cache __HUGE__ *)foundi;
                if((foundv=la_Find(fi->v.leaf,&ic,__full_compare_cache))!=NULL)
diff -Naurp biew-562-orig/biewlib/sysdep/ia16/cmn_ix86.c biew-562/biewlib/sysdep/ia16/cmn_ix86.c
--- biew-562-orig/biewlib/sysdep/ia16/cmn_ix86.c	2006-08-12 21:56:49.000000000 +0200
+++ biew-562/biewlib/sysdep/ia16/cmn_ix86.c	2006-08-13 12:01:32.000000000 +0200
@@ -47,7 +47,7 @@ static unsigned long __NEAR__ __FASTCALL
   ctrl_arr = c_arr;
   /* align pointer on 16-byte boundary */
 
-  if((tUInt32)ctrl_arr & 15) ((tUInt32)ctrl_arr) += 16-((tUInt32)ctrl_arr&15);
+  if((tUInt32)ctrl_arr & 15) ctrl_arr += 16-((tUInt32)ctrl_arr&15);
 
   memset(ctrl_arr,0,sizeof(ctrl_arr));
   if(time_interval)
diff -Naurp biew-562-orig/biewlib/sysdep/ia32/aclib_template.c biew-562/biewlib/sysdep/ia32/aclib_template.c
--- biew-562-orig/biewlib/sysdep/ia32/aclib_template.c	2006-08-12 21:56:49.000000000 +0200
+++ biew-562/biewlib/sysdep/ia32/aclib_template.c	2006-08-13 12:03:54.000000000 +0200
@@ -159,8 +159,8 @@ static void * RENAME(fast_memcpy)(void *
 		"movntps %%xmm2, 32(%1)\n"
 		"movntps %%xmm3, 48(%1)\n"
 		:: "r" (from), "r" (to) : "memory");
-		((const unsigned char *)from)+=64;
-		((unsigned char *)to)+=64;
+		from += 64;
+		to += 64;
 	}
 	else
 	/*
@@ -181,8 +181,8 @@ static void * RENAME(fast_memcpy)(void *
 		"movntps %%xmm2, 32(%1)\n"
 		"movntps %%xmm3, 48(%1)\n"
 		:: "r" (from), "r" (to) : "memory");
-		((const unsigned char *)from)+=64;
-		((unsigned char *)to)+=64;
+		from += 64;
+		to+=64;
 	}
 #else
 	// Align destination at BLOCK_SIZE boundary
@@ -209,8 +209,8 @@ static void * RENAME(fast_memcpy)(void *
 		MOVNTQ" %%mm6, 48(%1)\n"
 		MOVNTQ" %%mm7, 56(%1)\n"
 		:: "r" (from), "r" (to) : "memory");
-		((const unsigned char *)from)+=64;
-		((unsigned char *)to)+=64;
+		from+=64;
+		to+=64;
 	}
 
 	// Pure Assembly cuz gcc is a bit unpredictable ;)
@@ -297,8 +297,8 @@ static void * RENAME(fast_memcpy)(void *
 		MOVNTQ" %%mm6, 48(%1)\n"
 		MOVNTQ" %%mm7, 56(%1)\n"
 		:: "r" (from), "r" (to) : "memory");
-		((const unsigned char *)from)+=64;
-		((unsigned char *)to)+=64;
+		from+=64;
+		to+=64;
 	}
 
 #endif /* Have SSE */
@@ -367,7 +367,7 @@ static void * RENAME(fast_memset)(void *
 		"movntps %%xmm0, 96(%0)\n"
 		"movntps %%xmm0, 112(%0)\n"
 		:: "r" (to) : "memory");
-		((unsigned char *)to)+=128;
+		to+=128;
 	}
 #else
 	__asm__ __volatile__(
@@ -393,7 +393,7 @@ static void * RENAME(fast_memset)(void *
 		MOVNTQ" %%mm0, 112(%0)\n"
 		MOVNTQ" %%mm0, 120(%0)\n"
 		:: "r" (to) : "memory");
-		((unsigned char *)to)+=128;
+		to+=128;
 	}
 #endif /* Have SSE */
 #ifdef HAVE_MMX2
diff -Naurp biew-562-orig/biewlib/tw_class.c biew-562/biewlib/tw_class.c
--- biew-562-orig/biewlib/tw_class.c	2006-08-12 21:56:50.000000000 +0200
+++ biew-562/biewlib/tw_class.c	2006-08-13 12:01:32.000000000 +0200
@@ -71,6 +71,6 @@ void __FASTCALL__ twcDestroyClassSet(voi
 TwClass * __FASTCALL__ twcFindClass(const char *name)
 {
  TwClass key;
- (const char *)(key.name) = name;
+ key.name = name;
  return (TwClass *)la_Find(class_set,&key, comp_class);
 }
diff -Naurp biew-562-orig/biewlib/twin.c biew-562/biewlib/twin.c
--- biew-562-orig/biewlib/twin.c	2006-08-12 21:56:50.000000000 +0200
+++ biew-562/biewlib/twin.c	2006-08-13 12:01:32.000000000 +0200
@@ -1891,9 +1891,9 @@ int __FASTCALL__ twPutS(const char *str)
        strcpy(__nls,str);
        __nls_OemToOsdep((unsigned char *)__nls,len);
      }
-     else (const char *)__nls = str;
+     else __nls = str;
   }
-  else (const char *)__nls = str;
+  else __nls = str;
   __nls_ptr = __nls;
   __oem_ptr = str;
   vidx = active->cur_x + active->cur_y*active->wwidth;