File: 50-narrowing-conversion-fix.patch

package info (click to toggle)
dx 1%3A4.4.4-19
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 56,128 kB
  • sloc: ansic: 365,481; cpp: 156,584; sh: 10,872; java: 10,641; makefile: 2,294; javascript: 837; awk: 444; yacc: 327
file content (281 lines) | stat: -rw-r--r-- 12,384 bytes parent folder | download | duplicates (6)
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
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
Description: Narrowing conversion fix
  This patch fixes narrowing conversion errors when assigning values >127
  to signed chars with GCC 6.
Bug-Debian: https://bugs.debian.org/811731
Author: Graham Inggs <ginggs@debian.org>
Last-Update: 2016-02-20
--- a/src/uipp/dxuilib/ticks_in.bm
+++ b/src/uipp/dxuilib/ticks_in.bm
@@ -1,6 +1,6 @@
 #define ticks_in_width 18
 #define ticks_in_height 16
-static char ticks_in_bits[] = {
+static unsigned char ticks_in_bits[] = {
    0x02, 0x00, 0x00, 0x02, 0x00, 0x00, 0x02, 0x00, 0x00, 0x02, 0x00, 0x00,
    0x02, 0x00, 0x00, 0x02, 0x00, 0x00, 0x02, 0x00, 0x00, 0x82, 0x20, 0x00,
    0x82, 0x20, 0x00, 0x92, 0x24, 0x01, 0x92, 0x24, 0x01, 0x92, 0x24, 0x01,
--- a/src/uipp/dxuilib/ticks_in_ins.bm
+++ b/src/uipp/dxuilib/ticks_in_ins.bm
@@ -1,6 +1,6 @@
 #define ticks_in_ins_width 18
 #define ticks_in_ins_height 16
-static char ticks_in_ins_bits[] = {
+static unsigned char ticks_in_ins_bits[] = {
    0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x00, 0x00,
    0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x00, 0x00,
    0x82, 0x20, 0x00, 0x10, 0x04, 0x01, 0x82, 0x20, 0x00, 0x10, 0x04, 0x01,
--- a/src/uipp/dxuilib/ticks_out.bm
+++ b/src/uipp/dxuilib/ticks_out.bm
@@ -1,6 +1,6 @@
 #define ticks_out_width 18
 #define ticks_out_height 16
-static char ticks_out_bits[] = {
+static unsigned char ticks_out_bits[] = {
    0x02, 0x00, 0x00, 0x02, 0x00, 0x00, 0x02, 0x00, 0x00, 0x02, 0x00, 0x00,
    0x02, 0x00, 0x00, 0x02, 0x00, 0x00, 0x02, 0x00, 0x00, 0x02, 0x00, 0x00,
    0x02, 0x00, 0x00, 0x02, 0x00, 0x00, 0xfe, 0xff, 0x03, 0x24, 0x49, 0x02,
--- a/src/uipp/dxuilib/ticks_out_ins.bm
+++ b/src/uipp/dxuilib/ticks_out_ins.bm
@@ -1,6 +1,6 @@
 #define ticks_out_ins_width 18
 #define ticks_out_ins_height 16
-static char ticks_out_ins_bits[] = {
+static unsigned char ticks_out_ins_bits[] = {
    0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x00, 0x00,
    0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x00, 0x00,
    0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0xaa, 0xaa, 0x02, 0x04, 0x41, 0x00,
--- a/src/uipp/dxuilib/AutoAxesDialog.C
+++ b/src/uipp/dxuilib/AutoAxesDialog.C
@@ -1791,16 +1791,16 @@
 	    XmNdepth, &depth, XmNscreen, &scr, NULL);
 	Pixel fg = BlackPixelOfScreen(scr);
 	AutoAxesDialog::TicksIn = XCreatePixmapFromBitmapData (XtDisplay(root), 
-	    XtWindow(root), ticks_in_bits, ticks_in_width, ticks_in_height,
+	    XtWindow(root), (char *)ticks_in_bits, ticks_in_width, ticks_in_height,
 	    fg, bg, depth);
 	AutoAxesDialog::TicksOut = XCreatePixmapFromBitmapData (XtDisplay(root), 
-	    XtWindow(root), ticks_out_bits, ticks_out_width, ticks_out_height,
+	    XtWindow(root), (char *)ticks_out_bits, ticks_out_width, ticks_out_height,
 	    fg, bg, depth);
 	AutoAxesDialog::TicksInGrey = XCreatePixmapFromBitmapData (XtDisplay(root), 
-	    XtWindow(root), ticks_in_ins_bits, ticks_in_ins_width, ticks_in_ins_height,
+	    XtWindow(root), (char *)ticks_in_ins_bits, ticks_in_ins_width, ticks_in_ins_height,
 	    fg, bg, depth);
 	AutoAxesDialog::TicksOutGrey = XCreatePixmapFromBitmapData (XtDisplay(root), 
-	    XtWindow(root),ticks_out_ins_bits, ticks_out_ins_width, ticks_out_ins_height,
+	    XtWindow(root), (char *)ticks_out_ins_bits, ticks_out_ins_width, ticks_out_ins_height,
 	    fg, bg, depth);
 
 
--- a/src/uipp/dxuilib/anchor.bm
+++ b/src/uipp/dxuilib/anchor.bm
@@ -2,7 +2,7 @@
 #define anchor_height 17
 #define anchor_x_hot -1
 #define anchor_y_hot -1
-static char anchor_bits[] = {
+static unsigned char anchor_bits[] = {
    0x80, 0x03, 0x00, 0x40, 0x05, 0x00, 0xc0, 0x02, 0x00, 0x40, 0x05, 0x00,
    0x80, 0x02, 0x00, 0x10, 0x11, 0x00, 0x30, 0x09, 0x00, 0x50, 0x15, 0x00,
    0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x83, 0x82, 0x00, 0x85, 0x41, 0x01,
--- a/src/uipp/dxuilib/DXWindow.C
+++ b/src/uipp/dxuilib/DXWindow.C
@@ -245,7 +245,7 @@
             XCreatePixmapFromBitmapData
                 (XtDisplay(this->menuBar),
                  wind,
-                 anchor_bits,
+                 (char *)anchor_bits,
                  anchor_width,
                  anchor_height,
                  foreground,
--- a/src/uipp/dxuilib/anim_mask.bm
+++ b/src/uipp/dxuilib/anim_mask.bm
@@ -1,6 +1,6 @@
 #define anim_mask_width 90
 #define anim_mask_height 23
-static char anim_mask_bits[] = {
+static unsigned char anim_mask_bits[] = {
    0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
    0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
    0xf0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x3f, 0x00,
--- a/src/uipp/dxuilib/PageTab.C
+++ b/src/uipp/dxuilib/PageTab.C
@@ -96,9 +96,9 @@
         PageTab::DragIcon = this->createDragIcon(pagedrag_width, pagedrag_height,
 	     (char *)pagedrag_bits, (char *)pagedragmask_bits);
 	PageTab::AnimationPixmap = XCreateBitmapFromData(XtDisplay(p),
-	      XtWindow(p), animation_bits, animation_width, animation_height);
+	      XtWindow(p), (char *)animation_bits, animation_width, animation_height);
 	      PageTab::AnimationMaskPixmap = XCreateBitmapFromData(XtDisplay(p),
-	      XtWindow(p), anim_mask_bits, anim_mask_width, anim_mask_height);
+	      XtWindow(p), (char *)anim_mask_bits, anim_mask_width, anim_mask_height);
 	PageTab::ClassInitialized = TRUE;
     }
 
--- a/src/uipp/dxuilib/animation.bm
+++ b/src/uipp/dxuilib/animation.bm
@@ -1,6 +1,6 @@
 #define animation_width 90
 #define animation_height 23
-static char animation_bits[] = {
+static unsigned char animation_bits[] = {
    0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
    0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
    0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
--- a/src/uipp/dxuilib/pagedrag.bm
+++ b/src/uipp/dxuilib/pagedrag.bm
@@ -1,6 +1,6 @@
 #define pagedrag_width 32
 #define pagedrag_height 32
-static char pagedrag_bits[] = {
+static unsigned char pagedrag_bits[] = {
    0x00, 0x00, 0x00, 0x00, 0xfc, 0x3f, 0x00, 0x00, 0x04, 0x30, 0x00, 0x00,
    0x04, 0xf0, 0x01, 0x00, 0x04, 0xb0, 0x01, 0x00, 0x07, 0xf0, 0xff, 0x0f,
    0x01, 0x00, 0x00, 0x0c, 0x01, 0x00, 0x00, 0x0c, 0x01, 0x00, 0x00, 0x7c,
--- a/src/uipp/dxuilib/pagedragmask.bm
+++ b/src/uipp/dxuilib/pagedragmask.bm
@@ -1,6 +1,6 @@
 #define pagedragmask_width 32
 #define pagedragmask_height 32
-static char pagedragmask_bits[] = {
+static unsigned char pagedragmask_bits[] = {
    0x00, 0x00, 0x00, 0x00, 0xfc, 0x3f, 0x00, 0x00, 0xfc, 0x3f, 0x00, 0x00,
    0x5c, 0xf5, 0x01, 0x00, 0xac, 0xfa, 0x01, 0x00, 0x5f, 0xf5, 0xff, 0x0f,
    0xaf, 0xfa, 0xff, 0x0f, 0x57, 0x55, 0x55, 0x0d, 0xab, 0xaa, 0xaa, 0x7e,
--- a/src/uipp/dxuilib/postit.bm
+++ b/src/uipp/dxuilib/postit.bm
@@ -2,7 +2,7 @@
 #define postit_height 24
 #define postit_x_hot 11
 #define postit_y_hot 0
-static char postit_bits[] = {
+static unsigned char postit_bits[] = {
    0x00, 0x00, 0x00, 0xaa, 0xaa, 0xaa, 0x54, 0x55, 0xd5, 0xaa, 0xaa, 0xaa,
    0x54, 0x41, 0xd5, 0xaa, 0xa8, 0xaa, 0x54, 0x75, 0xd5, 0xaa, 0xbc, 0xaa,
    0x54, 0x55, 0xd5, 0xaa, 0xaa, 0xaa, 0x54, 0x41, 0xd5, 0xaa, 0xa8, 0xaa,
--- a/src/uipp/dxuilib/VPEPostIt.C
+++ b/src/uipp/dxuilib/VPEPostIt.C
@@ -213,7 +213,7 @@
 	XFreePixmap(d, this->bg_pixmap);
 	this->bg_pixmap = NUL(Pixmap);
     }
-    this->bg_pixmap = XCreatePixmapFromBitmapData(d, w, postit_bits,
+    this->bg_pixmap = XCreatePixmapFromBitmapData(d, w, (char *)postit_bits,
 	postit_width, postit_height, fg, bg, depth);
     XtVaSetValues (this->customPart,
 	XmNlabelType, XmPIXMAP,
--- a/src/uipp/base/plus.bm
+++ b/src/uipp/base/plus.bm
@@ -1,6 +1,6 @@
 #define plus_width 12
 #define plus_height 14
-static char plus_bits[] = {
+static unsigned char plus_bits[] = {
    0x00, 0x00, 0x00, 0x00, 0xfe, 0x0f, 0x02, 0x08, 0x42, 0x08, 0x42, 0x08,
    0x42, 0x08, 0xfa, 0x0b, 0x42, 0x08, 0x42, 0x08, 0x42, 0x08, 0x02, 0x08,
    0xfe, 0x0f, 0x00, 0x00};
--- a/src/uipp/base/TreeView.C
+++ b/src/uipp/base/TreeView.C
@@ -316,9 +316,9 @@
     }
 
     if (TreeView::Plus == XmUNSPECIFIED_PIXMAP) {
-	TreeView::Plus = XCreatePixmapFromBitmapData(d,win,plus_bits,plus_width,
+	TreeView::Plus = XCreatePixmapFromBitmapData(d,win,(char *)plus_bits,plus_width,
 	    plus_height,this->line_color,bg,depth);
-	TreeView::Minus = XCreatePixmapFromBitmapData(d,win,minus_bits,minus_width,
+	TreeView::Minus = XCreatePixmapFromBitmapData(d,win,(char *)minus_bits,minus_width,
 	    minus_height,this->line_color,bg,depth);
     }
 
--- a/src/uipp/base/minus.bm
+++ b/src/uipp/base/minus.bm
@@ -1,6 +1,6 @@
 #define minus_width 12
 #define minus_height 14
-static char minus_bits[] = {
+static unsigned char minus_bits[] = {
    0x00, 0x00, 0x00, 0x00, 0xfe, 0x0f, 0x02, 0x08, 0x02, 0x08, 0x02, 0x08,
    0x02, 0x08, 0xfa, 0x0b, 0x02, 0x08, 0x02, 0x08, 0x02, 0x08, 0x02, 0x08,
    0xfe, 0x0f, 0x00, 0x00};
--- a/src/uipp/prompter/col_insens.bm
+++ b/src/uipp/prompter/col_insens.bm
@@ -1,6 +1,6 @@
 #define col_insens_width 20
 #define col_insens_height 20
-static char col_insens_bits[] = {
+static unsigned char col_insens_bits[] = {
    0x00, 0x00, 0x00, 0x55, 0x55, 0x05, 0x00, 0x00, 0x08, 0x00, 0x80, 0x02,
    0x00, 0x28, 0x00, 0x80, 0x02, 0x00, 0x28, 0x00, 0x00, 0x02, 0x00, 0x00,
    0x55, 0x55, 0x05, 0x00, 0x00, 0x08, 0x00, 0x80, 0x02, 0x00, 0x28, 0x00,
--- a/src/uipp/prompter/col_sens.bm
+++ b/src/uipp/prompter/col_sens.bm
@@ -1,6 +1,6 @@
 #define col_sens_width 20
 #define col_sens_height 20
-static char col_sens_bits[] = {
+static unsigned char col_sens_bits[] = {
    0x00, 0x00, 0x00, 0xff, 0xff, 0x0f, 0x00, 0x00, 0x0c, 0x00, 0xc0, 0x03,
    0x00, 0x3c, 0x00, 0xc0, 0x03, 0x00, 0x3c, 0x00, 0x00, 0x03, 0x00, 0x00,
    0xff, 0xff, 0x0f, 0x00, 0x00, 0x0c, 0x00, 0xc0, 0x03, 0x00, 0x3c, 0x00,
--- a/src/uipp/prompter/row_insens.bm
+++ b/src/uipp/prompter/row_insens.bm
@@ -1,6 +1,6 @@
 #define row_insens_width 20
 #define row_insens_height 20
-static char row_insens_bits[] = {
+static unsigned char row_insens_bits[] = {
    0x02, 0x81, 0x00, 0x80, 0x40, 0x00, 0x02, 0x81, 0x00, 0x40, 0x20, 0x00,
    0x02, 0x81, 0x00, 0x40, 0x20, 0x00, 0x02, 0x81, 0x00, 0x20, 0x10, 0x00,
    0x02, 0x81, 0x00, 0x20, 0x10, 0x00, 0x02, 0x81, 0x00, 0x10, 0x08, 0x00,
--- a/src/uipp/prompter/row_sens.bm
+++ b/src/uipp/prompter/row_sens.bm
@@ -1,6 +1,6 @@
 #define row_sens_width 20
 #define row_sens_height 20
-static char row_sens_bits[] = {
+static unsigned char row_sens_bits[] = {
    0x82, 0xc1, 0x00, 0x82, 0xc1, 0x00, 0x42, 0xa1, 0x00, 0x42, 0xa1, 0x00,
    0x42, 0xa1, 0x00, 0x42, 0xa1, 0x00, 0x22, 0x91, 0x00, 0x22, 0x91, 0x00,
    0x22, 0x91, 0x00, 0x22, 0x91, 0x00, 0x12, 0x89, 0x00, 0x12, 0x89, 0x00,
--- a/src/uipp/prompter/grid1.bm
+++ b/src/uipp/prompter/grid1.bm
@@ -1,6 +1,6 @@
 #define grid1_width 37
 #define grid1_height 37
-static char grid1_bits[] = {
+static unsigned char grid1_bits[] = {
    0xff, 0xff, 0xff, 0xff, 0x1f, 0x41, 0x10, 0x04, 0x41, 0x10, 0x41, 0x10,
    0x04, 0x41, 0x10, 0x41, 0x10, 0x04, 0x41, 0x10, 0x41, 0x10, 0x04, 0x41,
    0x10, 0x41, 0x10, 0x04, 0x41, 0x10, 0xff, 0xff, 0xff, 0xff, 0x1f, 0x41,
--- a/src/uipp/prompter/grid2.bm
+++ b/src/uipp/prompter/grid2.bm
@@ -1,6 +1,6 @@
 #define grid2_width 37
 #define grid2_height 37
-static char grid2_bits[] = {
+static unsigned char grid2_bits[] = {
    0xff, 0xff, 0xff, 0xff, 0x1f, 0x41, 0x0a, 0x40, 0x02, 0x10, 0x41, 0x0a,
    0x40, 0x02, 0x10, 0x41, 0x0a, 0x40, 0x02, 0x10, 0xff, 0xff, 0xff, 0xff,
    0x1f, 0x41, 0x0a, 0x40, 0x02, 0x10, 0x41, 0x0a, 0x40, 0x02, 0x10, 0xff,
--- a/src/uipp/prompter/grid3.bm
+++ b/src/uipp/prompter/grid3.bm
@@ -1,6 +1,6 @@
 #define grid3_width 37
 #define grid3_height 37
-static char grid3_bits[] = {
+static unsigned char grid3_bits[] = {
    0x00, 0xf0, 0xff, 0x01, 0x00, 0x00, 0x0f, 0x04, 0x1e, 0x00, 0xe0, 0x00,
    0x04, 0xe0, 0x00, 0x98, 0x00, 0x04, 0x20, 0x03, 0x86, 0x00, 0x04, 0x20,
    0x0c, 0x01, 0x01, 0x04, 0x10, 0x10, 0x01, 0x01, 0x04, 0x10, 0x10, 0x02,
--- a/src/uipp/prompter/grid4.bm
+++ b/src/uipp/prompter/grid4.bm
@@ -1,6 +1,6 @@
 #define grid4_width 37
 #define grid4_height 37
-static char grid4_bits[] = {
+static unsigned char grid4_bits[] = {
    0x00, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x06, 0x18, 0x00,
    0x00, 0x00, 0x00, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x30, 0x00, 0x00,
    0x00, 0x00, 0x30, 0x18, 0x00, 0x00, 0x00, 0x00, 0x18, 0x00, 0x00, 0x00,