Merge lp:~akopytov/percona-server/bug878404-5.5 into lp:percona-server/5.5
- bug878404-5.5
- Merge into 5.5
Status: | Merged |
---|---|
Approved by: | Alexey Kopytov |
Approved revision: | no longer in the source branch. |
Merged at revision: | 193 |
Proposed branch: | lp:~akopytov/percona-server/bug878404-5.5 |
Merge into: | lp:percona-server/5.5 |
Diff against target: |
741 lines (+729/-0) 2 files modified
patches/bug45702.patch (+728/-0) patches/series (+1/-0) |
To merge this branch: | bzr merge lp:~akopytov/percona-server/bug878404-5.5 |
Related bugs: |
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
Laurynas Biveinis (community) | Approve | ||
Review via email: mp+80496@code.launchpad.net |
Commit message
Description of the change
Alexey Kopytov (akopytov) wrote : | # |
Laurynas Biveinis (laurynas-biveinis) wrote : | # |
LGTM.
(This is a kind of bug that should not have happened in the first place, all those (uint) casts in the original code look just terrible.)
Laurynas Biveinis (laurynas-biveinis) wrote : | # |
(Found this while reviewing 5.1)
What is the largest supported size of DYNAMIC_ARRAY? The elements and max_element fields are ulong instead of uint. But get_index_dynamic returns signed int (now long), so if size_of_element == 1, get_index_dynamic will not work correctly for element indexes > LONG_MAX. size_t is able to hold the value of ret, but int/long not necessarily so.
Alexey Kopytov (akopytov) wrote : | # |
Yes, the return value of get_index_dynamic() must be signed because it returns -1 for a non-existing element. So the effective limit for dynamic array is LONG_MAX elements *if* get_index_dynamic() is used. I didn't want to change the interface to make the patch less intrusive. And it is enough for our purposes because:
- the value used to initialize it in sort.c is signed anyway
- get_index_dynamic() is not used in sort.c
Alexey Kopytov (akopytov) wrote : | # |
Setting to approved as the patch is identical to the already approved and merged 5.1 version: https:/
Laurynas Biveinis (laurynas-biveinis) wrote : | # |
LGTM
Preview Diff
1 | === added file 'patches/bug45702.patch' | |||
2 | --- patches/bug45702.patch 1970-01-01 00:00:00 +0000 | |||
3 | +++ patches/bug45702.patch 2011-10-27 07:36:24 +0000 | |||
4 | @@ -0,0 +1,728 @@ | |||
5 | 1 | --- a/include/my_sys.h | ||
6 | 2 | +++ b/include/my_sys.h | ||
7 | 3 | @@ -320,8 +320,8 @@ | ||
8 | 4 | typedef struct st_dynamic_array | ||
9 | 5 | { | ||
10 | 6 | uchar *buffer; | ||
11 | 7 | - uint elements,max_element; | ||
12 | 8 | - uint alloc_increment; | ||
13 | 9 | + ulong elements, max_element; | ||
14 | 10 | + ulong alloc_increment; | ||
15 | 11 | uint size_of_element; | ||
16 | 12 | } DYNAMIC_ARRAY; | ||
17 | 13 | |||
18 | 14 | @@ -758,21 +758,21 @@ | ||
19 | 15 | #define my_init_dynamic_array2(A,B,C,D,E) init_dynamic_array2(A,B,C,D,E) | ||
20 | 16 | #define my_init_dynamic_array2_ci(A,B,C,D,E) init_dynamic_array2(A,B,C,D,E) | ||
21 | 17 | extern my_bool init_dynamic_array2(DYNAMIC_ARRAY *array, uint element_size, | ||
22 | 18 | - void *init_buffer, uint init_alloc, | ||
23 | 19 | - uint alloc_increment); | ||
24 | 20 | + void *init_buffer, ulong init_alloc, | ||
25 | 21 | + ulong alloc_increment); | ||
26 | 22 | /* init_dynamic_array() function is deprecated */ | ||
27 | 23 | extern my_bool init_dynamic_array(DYNAMIC_ARRAY *array, uint element_size, | ||
28 | 24 | - uint init_alloc, uint alloc_increment); | ||
29 | 25 | + ulong init_alloc, ulong alloc_increment); | ||
30 | 26 | extern my_bool insert_dynamic(DYNAMIC_ARRAY *array,uchar * element); | ||
31 | 27 | extern uchar *alloc_dynamic(DYNAMIC_ARRAY *array); | ||
32 | 28 | extern uchar *pop_dynamic(DYNAMIC_ARRAY*); | ||
33 | 29 | -extern my_bool set_dynamic(DYNAMIC_ARRAY *array,uchar * element,uint array_index); | ||
34 | 30 | -extern my_bool allocate_dynamic(DYNAMIC_ARRAY *array, uint max_elements); | ||
35 | 31 | -extern void get_dynamic(DYNAMIC_ARRAY *array,uchar * element,uint array_index); | ||
36 | 32 | +extern my_bool set_dynamic(DYNAMIC_ARRAY *array, uchar * element, ulong array_index); | ||
37 | 33 | +extern my_bool allocate_dynamic(DYNAMIC_ARRAY *array, ulong max_elements); | ||
38 | 34 | +extern void get_dynamic(DYNAMIC_ARRAY *array, uchar * element, ulong array_index); | ||
39 | 35 | extern void delete_dynamic(DYNAMIC_ARRAY *array); | ||
40 | 36 | -extern void delete_dynamic_element(DYNAMIC_ARRAY *array, uint array_index); | ||
41 | 37 | +extern void delete_dynamic_element(DYNAMIC_ARRAY *array, ulong array_index); | ||
42 | 38 | extern void freeze_size(DYNAMIC_ARRAY *array); | ||
43 | 39 | -extern int get_index_dynamic(DYNAMIC_ARRAY *array, uchar * element); | ||
44 | 40 | +extern long get_index_dynamic(DYNAMIC_ARRAY *array, uchar * element); | ||
45 | 41 | #define dynamic_array_ptr(array,array_index) ((array)->buffer+(array_index)*(array)->size_of_element) | ||
46 | 42 | #define dynamic_element(array,array_index,type) ((type)((array)->buffer) +(array_index)) | ||
47 | 43 | #define push_dynamic(A,B) insert_dynamic((A),(B)) | ||
48 | 44 | --- a/mysys/array.c | ||
49 | 45 | +++ b/mysys/array.c | ||
50 | 46 | @@ -41,8 +41,8 @@ | ||
51 | 47 | */ | ||
52 | 48 | |||
53 | 49 | my_bool init_dynamic_array2(DYNAMIC_ARRAY *array, uint element_size, | ||
54 | 50 | - void *init_buffer, uint init_alloc, | ||
55 | 51 | - uint alloc_increment) | ||
56 | 52 | + void *init_buffer, ulong init_alloc, | ||
57 | 53 | + ulong alloc_increment) | ||
58 | 54 | { | ||
59 | 55 | DBUG_ENTER("init_dynamic_array"); | ||
60 | 56 | if (!alloc_increment) | ||
61 | 57 | @@ -73,7 +73,7 @@ | ||
62 | 58 | } | ||
63 | 59 | |||
64 | 60 | my_bool init_dynamic_array(DYNAMIC_ARRAY *array, uint element_size, | ||
65 | 61 | - uint init_alloc, uint alloc_increment) | ||
66 | 62 | + ulong init_alloc, ulong alloc_increment) | ||
67 | 63 | { | ||
68 | 64 | /* placeholder to preserve ABI */ | ||
69 | 65 | return my_init_dynamic_array_ci(array, element_size, init_alloc, | ||
70 | 66 | @@ -196,7 +196,7 @@ | ||
71 | 67 | FALSE Ok | ||
72 | 68 | */ | ||
73 | 69 | |||
74 | 70 | -my_bool set_dynamic(DYNAMIC_ARRAY *array, uchar* element, uint idx) | ||
75 | 71 | +my_bool set_dynamic(DYNAMIC_ARRAY *array, uchar* element, ulong idx) | ||
76 | 72 | { | ||
77 | 73 | if (idx >= array->elements) | ||
78 | 74 | { | ||
79 | 75 | @@ -228,11 +228,11 @@ | ||
80 | 76 | TRUE Allocation of new memory failed | ||
81 | 77 | */ | ||
82 | 78 | |||
83 | 79 | -my_bool allocate_dynamic(DYNAMIC_ARRAY *array, uint max_elements) | ||
84 | 80 | +my_bool allocate_dynamic(DYNAMIC_ARRAY *array, ulong max_elements) | ||
85 | 81 | { | ||
86 | 82 | if (max_elements >= array->max_element) | ||
87 | 83 | { | ||
88 | 84 | - uint size; | ||
89 | 85 | + ulong size; | ||
90 | 86 | uchar *new_ptr; | ||
91 | 87 | size= (max_elements + array->alloc_increment)/array->alloc_increment; | ||
92 | 88 | size*= array->alloc_increment; | ||
93 | 89 | @@ -273,11 +273,11 @@ | ||
94 | 90 | idx Index of element wanted. | ||
95 | 91 | */ | ||
96 | 92 | |||
97 | 93 | -void get_dynamic(DYNAMIC_ARRAY *array, uchar* element, uint idx) | ||
98 | 94 | +void get_dynamic(DYNAMIC_ARRAY *array, uchar* element, ulong idx) | ||
99 | 95 | { | ||
100 | 96 | if (idx >= array->elements) | ||
101 | 97 | { | ||
102 | 98 | - DBUG_PRINT("warning",("To big array idx: %d, array size is %d", | ||
103 | 99 | + DBUG_PRINT("warning",("To big array idx: %lu, array size is %lu", | ||
104 | 100 | idx,array->elements)); | ||
105 | 101 | bzero(element,array->size_of_element); | ||
106 | 102 | return; | ||
107 | 103 | @@ -320,7 +320,7 @@ | ||
108 | 104 | idx Index of element to be deleted | ||
109 | 105 | */ | ||
110 | 106 | |||
111 | 107 | -void delete_dynamic_element(DYNAMIC_ARRAY *array, uint idx) | ||
112 | 108 | +void delete_dynamic_element(DYNAMIC_ARRAY *array, ulong idx) | ||
113 | 109 | { | ||
114 | 110 | char *ptr= (char*) array->buffer+array->size_of_element*idx; | ||
115 | 111 | array->elements--; | ||
116 | 112 | @@ -340,7 +340,7 @@ | ||
117 | 113 | |||
118 | 114 | void freeze_size(DYNAMIC_ARRAY *array) | ||
119 | 115 | { | ||
120 | 116 | - uint elements=max(array->elements,1); | ||
121 | 117 | + ulong elements= max(array->elements, 1); | ||
122 | 118 | |||
123 | 119 | /* | ||
124 | 120 | Do nothing if we are using a static buffer | ||
125 | 121 | @@ -368,7 +368,7 @@ | ||
126 | 122 | |||
127 | 123 | */ | ||
128 | 124 | |||
129 | 125 | -int get_index_dynamic(DYNAMIC_ARRAY *array, uchar* element) | ||
130 | 126 | +long get_index_dynamic(DYNAMIC_ARRAY *array, uchar* element) | ||
131 | 127 | { | ||
132 | 128 | size_t ret; | ||
133 | 129 | if (array->buffer > element) | ||
134 | 130 | --- a/storage/myisam/mi_check.c | ||
135 | 131 | +++ b/storage/myisam/mi_check.c | ||
136 | 132 | @@ -2429,7 +2429,7 @@ | ||
137 | 133 | |||
138 | 134 | if (_create_index_by_sort(&sort_param, | ||
139 | 135 | (my_bool) (!(param->testflag & T_VERBOSE)), | ||
140 | 136 | - (uint) param->sort_buffer_length)) | ||
141 | 137 | + param->sort_buffer_length)) | ||
142 | 138 | { | ||
143 | 139 | param->retry_repair=1; | ||
144 | 140 | goto err; | ||
145 | 141 | --- a/storage/myisam/sort.c | ||
146 | 142 | +++ b/storage/myisam/sort.c | ||
147 | 143 | @@ -45,42 +45,42 @@ | ||
148 | 144 | |||
149 | 145 | /* Functions defined in this file */ | ||
150 | 146 | |||
151 | 147 | -static ha_rows find_all_keys(MI_SORT_PARAM *info,uint keys, | ||
152 | 148 | +static ha_rows find_all_keys(MI_SORT_PARAM *info, ulong keys, | ||
153 | 149 | uchar **sort_keys, | ||
154 | 150 | - DYNAMIC_ARRAY *buffpek,int *maxbuffer, | ||
155 | 151 | + DYNAMIC_ARRAY *buffpek, long *maxbuffer, | ||
156 | 152 | IO_CACHE *tempfile, | ||
157 | 153 | IO_CACHE *tempfile_for_exceptions); | ||
158 | 154 | static int write_keys(MI_SORT_PARAM *info,uchar **sort_keys, | ||
159 | 155 | - uint count, BUFFPEK *buffpek,IO_CACHE *tempfile); | ||
160 | 156 | + ulong count, BUFFPEK *buffpek,IO_CACHE *tempfile); | ||
161 | 157 | static int write_key(MI_SORT_PARAM *info, uchar *key, | ||
162 | 158 | IO_CACHE *tempfile); | ||
163 | 159 | static int write_index(MI_SORT_PARAM *info,uchar * *sort_keys, | ||
164 | 160 | - uint count); | ||
165 | 161 | -static int merge_many_buff(MI_SORT_PARAM *info,uint keys, | ||
166 | 162 | + ulong count); | ||
167 | 163 | +static int merge_many_buff(MI_SORT_PARAM *info, ulong keys, | ||
168 | 164 | uchar * *sort_keys, | ||
169 | 165 | - BUFFPEK *buffpek,int *maxbuffer, | ||
170 | 166 | + BUFFPEK *buffpek, long *maxbuffer, | ||
171 | 167 | IO_CACHE *t_file); | ||
172 | 168 | -static uint read_to_buffer(IO_CACHE *fromfile,BUFFPEK *buffpek, | ||
173 | 169 | +static ulong read_to_buffer(IO_CACHE *fromfile,BUFFPEK *buffpek, | ||
174 | 170 | uint sort_length); | ||
175 | 171 | -static int merge_buffers(MI_SORT_PARAM *info,uint keys, | ||
176 | 172 | +static int merge_buffers(MI_SORT_PARAM *info, ulong keys, | ||
177 | 173 | IO_CACHE *from_file, IO_CACHE *to_file, | ||
178 | 174 | uchar * *sort_keys, BUFFPEK *lastbuff, | ||
179 | 175 | BUFFPEK *Fb, BUFFPEK *Tb); | ||
180 | 176 | -static int merge_index(MI_SORT_PARAM *,uint,uchar **,BUFFPEK *, int, | ||
181 | 177 | +static int merge_index(MI_SORT_PARAM *, ulong, uchar **, BUFFPEK *, long, | ||
182 | 178 | IO_CACHE *); | ||
183 | 179 | static int flush_ft_buf(MI_SORT_PARAM *info); | ||
184 | 180 | |||
185 | 181 | static int write_keys_varlen(MI_SORT_PARAM *info,uchar **sort_keys, | ||
186 | 182 | - uint count, BUFFPEK *buffpek, | ||
187 | 183 | + ulong count, BUFFPEK *buffpek, | ||
188 | 184 | IO_CACHE *tempfile); | ||
189 | 185 | -static uint read_to_buffer_varlen(IO_CACHE *fromfile,BUFFPEK *buffpek, | ||
190 | 186 | - uint sort_length); | ||
191 | 187 | +static ulong read_to_buffer_varlen(IO_CACHE *fromfile,BUFFPEK *buffpek, | ||
192 | 188 | + uint sort_length); | ||
193 | 189 | static int write_merge_key(MI_SORT_PARAM *info, IO_CACHE *to_file, | ||
194 | 190 | - uchar *key, uint sort_length, uint count); | ||
195 | 191 | + uchar *key, uint sort_length, ulong count); | ||
196 | 192 | static int write_merge_key_varlen(MI_SORT_PARAM *info, | ||
197 | 193 | IO_CACHE *to_file, | ||
198 | 194 | uchar* key, uint sort_length, | ||
199 | 195 | - uint count); | ||
200 | 196 | + ulong count); | ||
201 | 197 | static inline int | ||
202 | 198 | my_var_write(MI_SORT_PARAM *info, IO_CACHE *to_file, uchar *bufs); | ||
203 | 199 | |||
204 | 200 | @@ -101,8 +101,9 @@ | ||
205 | 201 | int _create_index_by_sort(MI_SORT_PARAM *info,my_bool no_messages, | ||
206 | 202 | ulong sortbuff_size) | ||
207 | 203 | { | ||
208 | 204 | - int error,maxbuffer,skr; | ||
209 | 205 | - uint memavl,old_memavl,keys,sort_length; | ||
210 | 206 | + int error; | ||
211 | 207 | + long maxbuffer, skr; | ||
212 | 208 | + ulong memavl, old_memavl, keys, sort_length; | ||
213 | 209 | DYNAMIC_ARRAY buffpek; | ||
214 | 210 | ha_rows records; | ||
215 | 211 | uchar **sort_keys; | ||
216 | 212 | @@ -136,25 +137,25 @@ | ||
217 | 213 | |||
218 | 214 | while (memavl >= MIN_SORT_BUFFER) | ||
219 | 215 | { | ||
220 | 216 | - if ((records < UINT_MAX32) && | ||
221 | 217 | + if ((records < ULONG_MAX) && | ||
222 | 218 | ((my_off_t) (records + 1) * | ||
223 | 219 | (sort_length + sizeof(char*)) <= (my_off_t) memavl)) | ||
224 | 220 | - keys= (uint)records+1; | ||
225 | 221 | + keys= (ulong) records + 1; | ||
226 | 222 | else | ||
227 | 223 | do | ||
228 | 224 | { | ||
229 | 225 | skr=maxbuffer; | ||
230 | 226 | - if (memavl < sizeof(BUFFPEK)*(uint) maxbuffer || | ||
231 | 227 | - (keys=(memavl-sizeof(BUFFPEK)*(uint) maxbuffer)/ | ||
232 | 228 | + if (memavl < sizeof(BUFFPEK) * (ulong) maxbuffer || | ||
233 | 229 | + (keys = (memavl - sizeof(BUFFPEK) * (ulong) maxbuffer) / | ||
234 | 230 | (sort_length+sizeof(char*))) <= 1 || | ||
235 | 231 | - keys < (uint) maxbuffer) | ||
236 | 232 | + keys < (ulong) maxbuffer) | ||
237 | 233 | { | ||
238 | 234 | mi_check_print_error(info->sort_info->param, | ||
239 | 235 | "myisam_sort_buffer_size is too small"); | ||
240 | 236 | goto err; | ||
241 | 237 | } | ||
242 | 238 | } | ||
243 | 239 | - while ((maxbuffer= (int) (records/(keys-1)+1)) != skr); | ||
244 | 240 | + while ((maxbuffer= (long) (records / (keys - 1) + 1)) != skr); | ||
245 | 241 | |||
246 | 242 | if ((sort_keys=(uchar **)my_malloc(keys*(sort_length+sizeof(char*))+ | ||
247 | 243 | HA_FT_MAXBYTELEN, MYF(0)))) | ||
248 | 244 | @@ -180,7 +181,7 @@ | ||
249 | 245 | (*info->lock_in_memory)(info->sort_info->param);/* Everything is allocated */ | ||
250 | 246 | |||
251 | 247 | if (!no_messages) | ||
252 | 248 | - printf(" - Searching for keys, allocating buffer for %d keys\n",keys); | ||
253 | 249 | + printf(" - Searching for keys, allocating buffer for %lu keys\n", keys); | ||
254 | 250 | |||
255 | 251 | if ((records=find_all_keys(info,keys,sort_keys,&buffpek,&maxbuffer, | ||
256 | 252 | &tempfile,&tempfile_for_exceptions)) | ||
257 | 253 | @@ -190,7 +191,7 @@ | ||
258 | 254 | { | ||
259 | 255 | if (!no_messages) | ||
260 | 256 | printf(" - Dumping %lu keys\n", (ulong) records); | ||
261 | 257 | - if (write_index(info,sort_keys, (uint) records)) | ||
262 | 258 | + if (write_index(info,sort_keys, (ulong) records)) | ||
263 | 259 | goto err; /* purecov: inspected */ | ||
264 | 260 | } | ||
265 | 261 | else | ||
266 | 262 | @@ -253,13 +254,13 @@ | ||
267 | 263 | |||
268 | 264 | /* Search after all keys and place them in a temp. file */ | ||
269 | 265 | |||
270 | 266 | -static ha_rows find_all_keys(MI_SORT_PARAM *info, uint keys, | ||
271 | 267 | +static ha_rows find_all_keys(MI_SORT_PARAM *info, ulong keys, | ||
272 | 268 | uchar **sort_keys, DYNAMIC_ARRAY *buffpek, | ||
273 | 269 | - int *maxbuffer, IO_CACHE *tempfile, | ||
274 | 270 | + long *maxbuffer, IO_CACHE *tempfile, | ||
275 | 271 | IO_CACHE *tempfile_for_exceptions) | ||
276 | 272 | { | ||
277 | 273 | int error; | ||
278 | 274 | - uint idx; | ||
279 | 275 | + ulong idx; | ||
280 | 276 | DBUG_ENTER("find_all_keys"); | ||
281 | 277 | |||
282 | 278 | idx=error=0; | ||
283 | 279 | @@ -308,8 +309,8 @@ | ||
284 | 280 | { | ||
285 | 281 | MI_SORT_PARAM *sort_param= (MI_SORT_PARAM*) arg; | ||
286 | 282 | int error; | ||
287 | 283 | - uint memavl,old_memavl,keys,sort_length; | ||
288 | 284 | - uint idx, maxbuffer; | ||
289 | 285 | + ulong memavl,old_memavl,keys,sort_length; | ||
290 | 286 | + ulong idx, maxbuffer; | ||
291 | 287 | uchar **sort_keys=0; | ||
292 | 288 | |||
293 | 289 | LINT_INIT(keys); | ||
294 | 290 | @@ -345,7 +346,7 @@ | ||
295 | 291 | sort_keys= (uchar **) NULL; | ||
296 | 292 | |||
297 | 293 | memavl= max(sort_param->sortbuff_size, MIN_SORT_BUFFER); | ||
298 | 294 | - idx= (uint)sort_param->sort_info->max_records; | ||
299 | 295 | + idx= (ulong) sort_param->sort_info->max_records; | ||
300 | 296 | sort_length= sort_param->key_length; | ||
301 | 297 | maxbuffer= 1; | ||
302 | 298 | |||
303 | 299 | @@ -356,21 +357,21 @@ | ||
304 | 300 | keys= idx+1; | ||
305 | 301 | else | ||
306 | 302 | { | ||
307 | 303 | - uint skr; | ||
308 | 304 | + ulong skr; | ||
309 | 305 | do | ||
310 | 306 | { | ||
311 | 307 | skr= maxbuffer; | ||
312 | 308 | if (memavl < sizeof(BUFFPEK)*maxbuffer || | ||
313 | 309 | (keys=(memavl-sizeof(BUFFPEK)*maxbuffer)/ | ||
314 | 310 | (sort_length+sizeof(char*))) <= 1 || | ||
315 | 311 | - keys < (uint) maxbuffer) | ||
316 | 312 | + keys < maxbuffer) | ||
317 | 313 | { | ||
318 | 314 | mi_check_print_error(sort_param->sort_info->param, | ||
319 | 315 | "myisam_sort_buffer_size is too small"); | ||
320 | 316 | goto err; | ||
321 | 317 | } | ||
322 | 318 | } | ||
323 | 319 | - while ((maxbuffer= (int) (idx/(keys-1)+1)) != skr); | ||
324 | 320 | + while ((maxbuffer= (idx/(keys-1)+1)) != skr); | ||
325 | 321 | } | ||
326 | 322 | if ((sort_keys= (uchar**) | ||
327 | 323 | my_malloc(keys*(sort_length+sizeof(char*))+ | ||
328 | 324 | @@ -399,7 +400,7 @@ | ||
329 | 325 | } | ||
330 | 326 | |||
331 | 327 | if (sort_param->sort_info->param->testflag & T_VERBOSE) | ||
332 | 328 | - printf("Key %d - Allocating buffer for %d keys\n", | ||
333 | 329 | + printf("Key %d - Allocating buffer for %lu keys\n", | ||
334 | 330 | sort_param->key + 1, keys); | ||
335 | 331 | sort_param->sort_keys= sort_keys; | ||
336 | 332 | |||
337 | 333 | @@ -553,7 +554,7 @@ | ||
338 | 334 | } | ||
339 | 335 | if (sinfo->buffpek.elements) | ||
340 | 336 | { | ||
341 | 337 | - uint maxbuffer=sinfo->buffpek.elements-1; | ||
342 | 338 | + ulong maxbuffer=sinfo->buffpek.elements-1; | ||
343 | 339 | if (!mergebuf) | ||
344 | 340 | { | ||
345 | 341 | length=param->sort_buffer_length; | ||
346 | 342 | @@ -576,7 +577,7 @@ | ||
347 | 343 | printf("Key %d - Merging %u keys\n",sinfo->key+1, sinfo->keys); | ||
348 | 344 | if (merge_many_buff(sinfo, keys, (uchar **)mergebuf, | ||
349 | 345 | dynamic_element(&sinfo->buffpek, 0, BUFFPEK *), | ||
350 | 346 | - (int*) &maxbuffer, &sinfo->tempfile)) | ||
351 | 347 | + (long *) &maxbuffer, &sinfo->tempfile)) | ||
352 | 348 | { | ||
353 | 349 | got_error=1; | ||
354 | 350 | continue; | ||
355 | 351 | @@ -640,7 +641,7 @@ | ||
356 | 352 | /* Write all keys in memory to file for later merge */ | ||
357 | 353 | |||
358 | 354 | static int write_keys(MI_SORT_PARAM *info, register uchar **sort_keys, | ||
359 | 355 | - uint count, BUFFPEK *buffpek, IO_CACHE *tempfile) | ||
360 | 356 | + ulong count, BUFFPEK *buffpek, IO_CACHE *tempfile) | ||
361 | 357 | { | ||
362 | 358 | uchar **end; | ||
363 | 359 | uint sort_length=info->key_length; | ||
364 | 360 | @@ -682,7 +683,7 @@ | ||
365 | 361 | |||
366 | 362 | static int write_keys_varlen(MI_SORT_PARAM *info, | ||
367 | 363 | register uchar **sort_keys, | ||
368 | 364 | - uint count, BUFFPEK *buffpek, | ||
369 | 365 | + ulong count, BUFFPEK *buffpek, | ||
370 | 366 | IO_CACHE *tempfile) | ||
371 | 367 | { | ||
372 | 368 | uchar **end; | ||
373 | 369 | @@ -727,7 +728,7 @@ | ||
374 | 370 | /* Write index */ | ||
375 | 371 | |||
376 | 372 | static int write_index(MI_SORT_PARAM *info, register uchar **sort_keys, | ||
377 | 373 | - register uint count) | ||
378 | 374 | + register ulong count) | ||
379 | 375 | { | ||
380 | 376 | DBUG_ENTER("write_index"); | ||
381 | 377 | |||
382 | 378 | @@ -744,11 +745,11 @@ | ||
383 | 379 | |||
384 | 380 | /* Merge buffers to make < MERGEBUFF2 buffers */ | ||
385 | 381 | |||
386 | 382 | -static int merge_many_buff(MI_SORT_PARAM *info, uint keys, | ||
387 | 383 | +static int merge_many_buff(MI_SORT_PARAM *info, ulong keys, | ||
388 | 384 | uchar **sort_keys, BUFFPEK *buffpek, | ||
389 | 385 | - int *maxbuffer, IO_CACHE *t_file) | ||
390 | 386 | + long *maxbuffer, IO_CACHE *t_file) | ||
391 | 387 | { | ||
392 | 388 | - register int i; | ||
393 | 389 | + register long i; | ||
394 | 390 | IO_CACHE t_file2, *from_file, *to_file, *temp; | ||
395 | 391 | BUFFPEK *lastbuff; | ||
396 | 392 | DBUG_ENTER("merge_many_buff"); | ||
397 | 393 | @@ -778,7 +779,7 @@ | ||
398 | 394 | if (flush_io_cache(to_file)) | ||
399 | 395 | break; /* purecov: inspected */ | ||
400 | 396 | temp=from_file; from_file=to_file; to_file=temp; | ||
401 | 397 | - *maxbuffer= (int) (lastbuff-buffpek)-1; | ||
402 | 398 | + *maxbuffer= (long) (lastbuff-buffpek)-1; | ||
403 | 399 | } | ||
404 | 400 | cleanup: | ||
405 | 401 | close_cached_file(to_file); /* This holds old result */ | ||
406 | 402 | @@ -807,18 +808,18 @@ | ||
407 | 403 | -1 Error | ||
408 | 404 | */ | ||
409 | 405 | |||
410 | 406 | -static uint read_to_buffer(IO_CACHE *fromfile, BUFFPEK *buffpek, | ||
411 | 407 | - uint sort_length) | ||
412 | 408 | +static ulong read_to_buffer(IO_CACHE *fromfile, BUFFPEK *buffpek, | ||
413 | 409 | + uint sort_length) | ||
414 | 410 | { | ||
415 | 411 | - register uint count; | ||
416 | 412 | - uint length; | ||
417 | 413 | + register ulong count; | ||
418 | 414 | + ulong length; | ||
419 | 415 | |||
420 | 416 | - if ((count=(uint) min((ha_rows) buffpek->max_keys,buffpek->count))) | ||
421 | 417 | + if ((count=(ulong) min((ha_rows) buffpek->max_keys,buffpek->count))) | ||
422 | 418 | { | ||
423 | 419 | if (mysql_file_pread(fromfile->file, (uchar*) buffpek->base, | ||
424 | 420 | (length= sort_length*count), | ||
425 | 421 | buffpek->file_pos, MYF_RW)) | ||
426 | 422 | - return((uint) -1); /* purecov: inspected */ | ||
427 | 423 | + return((ulong) -1); /* purecov: inspected */ | ||
428 | 424 | buffpek->key=buffpek->base; | ||
429 | 425 | buffpek->file_pos+= length; /* New filepos */ | ||
430 | 426 | buffpek->count-= count; | ||
431 | 427 | @@ -827,15 +828,15 @@ | ||
432 | 428 | return (count*sort_length); | ||
433 | 429 | } /* read_to_buffer */ | ||
434 | 430 | |||
435 | 431 | -static uint read_to_buffer_varlen(IO_CACHE *fromfile, BUFFPEK *buffpek, | ||
436 | 432 | +static ulong read_to_buffer_varlen(IO_CACHE *fromfile, BUFFPEK *buffpek, | ||
437 | 433 | uint sort_length) | ||
438 | 434 | { | ||
439 | 435 | - register uint count; | ||
440 | 436 | + register ulong count; | ||
441 | 437 | uint16 length_of_key = 0; | ||
442 | 438 | - uint idx; | ||
443 | 439 | + ulong idx; | ||
444 | 440 | uchar *buffp; | ||
445 | 441 | |||
446 | 442 | - if ((count=(uint) min((ha_rows) buffpek->max_keys,buffpek->count))) | ||
447 | 443 | + if ((count=(ulong) min((ha_rows) buffpek->max_keys,buffpek->count))) | ||
448 | 444 | { | ||
449 | 445 | buffp = buffpek->base; | ||
450 | 446 | |||
451 | 447 | @@ -843,11 +844,11 @@ | ||
452 | 448 | { | ||
453 | 449 | if (mysql_file_pread(fromfile->file, (uchar*)&length_of_key, | ||
454 | 450 | sizeof(length_of_key), buffpek->file_pos, MYF_RW)) | ||
455 | 451 | - return((uint) -1); | ||
456 | 452 | + return((ulong) -1); | ||
457 | 453 | buffpek->file_pos+=sizeof(length_of_key); | ||
458 | 454 | if (mysql_file_pread(fromfile->file, (uchar*) buffp, | ||
459 | 455 | length_of_key, buffpek->file_pos, MYF_RW)) | ||
460 | 456 | - return((uint) -1); | ||
461 | 457 | + return((ulong) -1); | ||
462 | 458 | buffpek->file_pos+=length_of_key; | ||
463 | 459 | buffp = buffp + sort_length; | ||
464 | 460 | } | ||
465 | 461 | @@ -861,9 +862,9 @@ | ||
466 | 462 | |||
467 | 463 | static int write_merge_key_varlen(MI_SORT_PARAM *info, | ||
468 | 464 | IO_CACHE *to_file, uchar* key, | ||
469 | 465 | - uint sort_length, uint count) | ||
470 | 466 | + uint sort_length, ulong count) | ||
471 | 467 | { | ||
472 | 468 | - uint idx; | ||
473 | 469 | + ulong idx; | ||
474 | 470 | uchar *bufs = key; | ||
475 | 471 | |||
476 | 472 | for (idx=1;idx<=count;idx++) | ||
477 | 473 | @@ -879,7 +880,7 @@ | ||
478 | 474 | |||
479 | 475 | static int write_merge_key(MI_SORT_PARAM *info __attribute__((unused)), | ||
480 | 476 | IO_CACHE *to_file, uchar *key, | ||
481 | 477 | - uint sort_length, uint count) | ||
482 | 478 | + uint sort_length, ulong count) | ||
483 | 479 | { | ||
484 | 480 | return my_b_write(to_file, key, (size_t) sort_length*count); | ||
485 | 481 | } | ||
486 | 482 | @@ -890,12 +891,13 @@ | ||
487 | 483 | */ | ||
488 | 484 | |||
489 | 485 | static int | ||
490 | 486 | -merge_buffers(MI_SORT_PARAM *info, uint keys, IO_CACHE *from_file, | ||
491 | 487 | +merge_buffers(MI_SORT_PARAM *info, ulong keys, IO_CACHE *from_file, | ||
492 | 488 | IO_CACHE *to_file, uchar **sort_keys, BUFFPEK *lastbuff, | ||
493 | 489 | BUFFPEK *Fb, BUFFPEK *Tb) | ||
494 | 490 | { | ||
495 | 491 | - int error; | ||
496 | 492 | - uint sort_length,maxcount; | ||
497 | 493 | + ulong error; | ||
498 | 494 | + uint sort_length; | ||
499 | 495 | + ulong maxcount; | ||
500 | 496 | ha_rows count; | ||
501 | 497 | my_off_t UNINIT_VAR(to_start_filepos); | ||
502 | 498 | uchar *strpos; | ||
503 | 499 | @@ -905,7 +907,7 @@ | ||
504 | 500 | DBUG_ENTER("merge_buffers"); | ||
505 | 501 | |||
506 | 502 | count=error=0; | ||
507 | 503 | - maxcount=keys/((uint) (Tb-Fb) +1); | ||
508 | 504 | + maxcount= keys / ((ulong) (Tb-Fb) + 1); | ||
509 | 505 | DBUG_ASSERT(maxcount > 0); | ||
510 | 506 | LINT_INIT(to_start_filepos); | ||
511 | 507 | if (to_file) | ||
512 | 508 | @@ -913,7 +915,7 @@ | ||
513 | 509 | strpos=(uchar*) sort_keys; | ||
514 | 510 | sort_length=info->key_length; | ||
515 | 511 | |||
516 | 512 | - if (init_queue(&queue,(uint) (Tb-Fb)+1,offsetof(BUFFPEK,key),0, | ||
517 | 513 | + if (init_queue(&queue, (uint) (Tb-Fb)+1, offsetof(BUFFPEK,key), 0, | ||
518 | 514 | (int (*)(void*, uchar *,uchar*)) info->key_cmp, | ||
519 | 515 | (void*) info)) | ||
520 | 516 | DBUG_RETURN(1); /* purecov: inspected */ | ||
521 | 517 | @@ -923,9 +925,8 @@ | ||
522 | 518 | count+= buffpek->count; | ||
523 | 519 | buffpek->base= strpos; | ||
524 | 520 | buffpek->max_keys=maxcount; | ||
525 | 521 | - strpos+= (uint) (error=(int) info->read_to_buffer(from_file,buffpek, | ||
526 | 522 | - sort_length)); | ||
527 | 523 | - if (error == -1) | ||
528 | 524 | + strpos+= (error= info->read_to_buffer(from_file,buffpek, sort_length)); | ||
529 | 525 | + if (error == (ulong) -1) | ||
530 | 526 | goto err; /* purecov: inspected */ | ||
531 | 527 | queue_insert(&queue,(uchar*) buffpek); | ||
532 | 528 | } | ||
533 | 529 | @@ -957,10 +958,10 @@ | ||
534 | 530 | buffpek->key+=sort_length; | ||
535 | 531 | if (! --buffpek->mem_count) | ||
536 | 532 | { | ||
537 | 533 | - if (!(error=(int) info->read_to_buffer(from_file,buffpek,sort_length))) | ||
538 | 534 | + if (!(error= info->read_to_buffer(from_file,buffpek,sort_length))) | ||
539 | 535 | { | ||
540 | 536 | uchar *base=buffpek->base; | ||
541 | 537 | - uint max_keys=buffpek->max_keys; | ||
542 | 538 | + ulong max_keys=buffpek->max_keys; | ||
543 | 539 | |||
544 | 540 | (void) queue_remove(&queue,0); | ||
545 | 541 | |||
546 | 542 | @@ -985,7 +986,7 @@ | ||
547 | 543 | break; /* One buffer have been removed */ | ||
548 | 544 | } | ||
549 | 545 | } | ||
550 | 546 | - else if (error == -1) | ||
551 | 547 | + else if (error == (ulong) -1) | ||
552 | 548 | goto err; /* purecov: inspected */ | ||
553 | 549 | queue_replaced(&queue); /* Top element has been replaced */ | ||
554 | 550 | } | ||
555 | 551 | @@ -1018,23 +1019,23 @@ | ||
556 | 552 | } | ||
557 | 553 | } | ||
558 | 554 | } | ||
559 | 555 | - while ((error=(int) info->read_to_buffer(from_file,buffpek,sort_length)) != -1 && | ||
560 | 556 | - error != 0); | ||
561 | 557 | + while ((error= info->read_to_buffer(from_file,buffpek,sort_length)) | ||
562 | 558 | + != (ulong) -1 && error != 0); | ||
563 | 559 | |||
564 | 560 | lastbuff->count=count; | ||
565 | 561 | if (to_file) | ||
566 | 562 | lastbuff->file_pos=to_start_filepos; | ||
567 | 563 | err: | ||
568 | 564 | delete_queue(&queue); | ||
569 | 565 | - DBUG_RETURN(error); | ||
570 | 566 | + DBUG_RETURN(error != 0); | ||
571 | 567 | } /* merge_buffers */ | ||
572 | 568 | |||
573 | 569 | |||
574 | 570 | /* Do a merge to output-file (save only positions) */ | ||
575 | 571 | |||
576 | 572 | static int | ||
577 | 573 | -merge_index(MI_SORT_PARAM *info, uint keys, uchar **sort_keys, | ||
578 | 574 | - BUFFPEK *buffpek, int maxbuffer, IO_CACHE *tempfile) | ||
579 | 575 | +merge_index(MI_SORT_PARAM *info, ulong keys, uchar **sort_keys, | ||
580 | 576 | + BUFFPEK *buffpek, long maxbuffer, IO_CACHE *tempfile) | ||
581 | 577 | { | ||
582 | 578 | DBUG_ENTER("merge_index"); | ||
583 | 579 | if (merge_buffers(info,keys,tempfile,(IO_CACHE*) 0,sort_keys,buffpek,buffpek, | ||
584 | 580 | --- /dev/null | ||
585 | 581 | +++ b/mysql-test/r/percona_bug45702.result | ||
586 | 582 | @@ -0,0 +1,21 @@ | ||
587 | 583 | +CREATE TABLE t1 (a BIGINT NOT NULL AUTO_INCREMENT PRIMARY KEY) ENGINE=MyISAM; | ||
588 | 584 | +INSERT INTO t1 VALUES (), (), (), (), (), (), (), (); | ||
589 | 585 | +INSERT INTO t1 SELECT NULL FROM t1; | ||
590 | 586 | +INSERT INTO t1 SELECT NULL FROM t1; | ||
591 | 587 | +INSERT INTO t1 SELECT NULL FROM t1; | ||
592 | 588 | +INSERT INTO t1 SELECT NULL FROM t1; | ||
593 | 589 | +INSERT INTO t1 SELECT NULL FROM t1; | ||
594 | 590 | +INSERT INTO t1 SELECT NULL FROM t1; | ||
595 | 591 | +INSERT INTO t1 SELECT NULL FROM t1; | ||
596 | 592 | +INSERT INTO t1 SELECT NULL FROM t1; | ||
597 | 593 | +INSERT INTO t1 SELECT NULL FROM t1; | ||
598 | 594 | +SET @old_myisam_sort_buffer_size = @@myisam_sort_buffer_size; | ||
599 | 595 | +SET @@myisam_sort_buffer_size = 4 * 1024 * 1024 * 1024; | ||
600 | 596 | +REPAIR TABLE t1; | ||
601 | 597 | +Table Op Msg_type Msg_text | ||
602 | 598 | +test.t1 repair status OK | ||
603 | 599 | +- recovering (with sort) MyISAM-table 'MYSQLD_DATADIR/test/t1' | ||
604 | 600 | +Data records: 4096 | ||
605 | 601 | +- Fixing index 1 | ||
606 | 602 | +SET @@myisam_sort_buffer_size = @old_myisam_sort_buffer_size; | ||
607 | 603 | +DROP TABLE t1; | ||
608 | 604 | --- /dev/null | ||
609 | 605 | +++ b/mysql-test/t/percona_bug45702.test | ||
610 | 606 | @@ -0,0 +1,34 @@ | ||
611 | 607 | +############################################################################### | ||
612 | 608 | +# Bug #45702: Impossible to specify myisam_sort_buffer > 4GB on 64 bit machines | ||
613 | 609 | +############################################################################### | ||
614 | 610 | + | ||
615 | 611 | +--source include/have_64bit.inc | ||
616 | 612 | + | ||
617 | 613 | +# Check that having data larger than MIN_SORT_BUFFER bytes can be handled by | ||
618 | 614 | +# _create_index_by_sort() with myisam_sort_buffer_size = 4 GB without errors. | ||
619 | 615 | +# The full test with large data volumes can not be a part of the test suite. | ||
620 | 616 | + | ||
621 | 617 | +CREATE TABLE t1 (a BIGINT NOT NULL AUTO_INCREMENT PRIMARY KEY) ENGINE=MyISAM; | ||
622 | 618 | +INSERT INTO t1 VALUES (), (), (), (), (), (), (), (); | ||
623 | 619 | +INSERT INTO t1 SELECT NULL FROM t1; | ||
624 | 620 | +INSERT INTO t1 SELECT NULL FROM t1; | ||
625 | 621 | +INSERT INTO t1 SELECT NULL FROM t1; | ||
626 | 622 | +INSERT INTO t1 SELECT NULL FROM t1; | ||
627 | 623 | +INSERT INTO t1 SELECT NULL FROM t1; | ||
628 | 624 | +INSERT INTO t1 SELECT NULL FROM t1; | ||
629 | 625 | +INSERT INTO t1 SELECT NULL FROM t1; | ||
630 | 626 | +INSERT INTO t1 SELECT NULL FROM t1; | ||
631 | 627 | +INSERT INTO t1 SELECT NULL FROM t1; | ||
632 | 628 | + | ||
633 | 629 | +SET @old_myisam_sort_buffer_size = @@myisam_sort_buffer_size; | ||
634 | 630 | +SET @@myisam_sort_buffer_size = 4 * 1024 * 1024 * 1024; | ||
635 | 631 | + | ||
636 | 632 | +REPAIR TABLE t1; | ||
637 | 633 | + | ||
638 | 634 | +--let $MYSQLD_DATADIR= `select @@datadir` | ||
639 | 635 | +--replace_result $MYSQLD_DATADIR MYSQLD_DATADIR | ||
640 | 636 | +--exec $MYISAMCHK -r --sort_buffer_size=4G $MYSQLD_DATADIR/test/t1 | ||
641 | 637 | + | ||
642 | 638 | +SET @@myisam_sort_buffer_size = @old_myisam_sort_buffer_size; | ||
643 | 639 | + | ||
644 | 640 | +DROP TABLE t1; | ||
645 | 641 | --- a/sql/opt_range.cc | ||
646 | 642 | +++ b/sql/opt_range.cc | ||
647 | 643 | @@ -11716,7 +11716,7 @@ | ||
648 | 644 | } | ||
649 | 645 | if (min_max_ranges.elements > 0) | ||
650 | 646 | { | ||
651 | 647 | - fprintf(DBUG_FILE, "%*susing %d quick_ranges for MIN/MAX:\n", | ||
652 | 648 | + fprintf(DBUG_FILE, "%*susing %lu quick_ranges for MIN/MAX:\n", | ||
653 | 649 | indent, "", min_max_ranges.elements); | ||
654 | 650 | } | ||
655 | 651 | } | ||
656 | 652 | --- a/mysys/my_pread.c | ||
657 | 653 | +++ b/mysys/my_pread.c | ||
658 | 654 | @@ -49,6 +49,7 @@ | ||
659 | 655 | myf MyFlags) | ||
660 | 656 | { | ||
661 | 657 | size_t readbytes; | ||
662 | 658 | + size_t total_readbytes= 0; | ||
663 | 659 | int error= 0; | ||
664 | 660 | #if !defined (HAVE_PREAD) && !defined (_WIN32) | ||
665 | 661 | int save_errno; | ||
666 | 662 | @@ -76,8 +77,30 @@ | ||
667 | 663 | #endif | ||
668 | 664 | error= (readbytes != Count); | ||
669 | 665 | #endif | ||
670 | 666 | + if (readbytes > 0) | ||
671 | 667 | + total_readbytes+= readbytes; | ||
672 | 668 | + | ||
673 | 669 | if(error) | ||
674 | 670 | { | ||
675 | 671 | + if (readbytes > 0 && readbytes < Count && errno == 0) | ||
676 | 672 | + { | ||
677 | 673 | + /* | ||
678 | 674 | + pread() may return less bytes than requested even if enough bytes are | ||
679 | 675 | + available according to the Linux man page. | ||
680 | 676 | + This makes determining the end-of-file condition a bit harder. | ||
681 | 677 | + We just do another pread() call to see if more bytes can be read, | ||
682 | 678 | + since all my_pread() users expect it to always return all available | ||
683 | 679 | + bytes. For end-of-file 0 bytes is returned. This can never be the case | ||
684 | 680 | + for a partial read, since according to the man page, -1 is returned | ||
685 | 681 | + with errno set to EINTR if no data has been read. | ||
686 | 682 | + */ | ||
687 | 683 | + Buffer+= readbytes; | ||
688 | 684 | + offset+= readbytes; | ||
689 | 685 | + Count-= readbytes; | ||
690 | 686 | + | ||
691 | 687 | + continue; | ||
692 | 688 | + } | ||
693 | 689 | + | ||
694 | 690 | my_errno= errno ? errno : -1; | ||
695 | 691 | if (errno == 0 || (readbytes != (size_t) -1 && | ||
696 | 692 | (MyFlags & (MY_NABP | MY_FNABP)))) | ||
697 | 693 | @@ -107,7 +130,7 @@ | ||
698 | 694 | } | ||
699 | 695 | if (MyFlags & (MY_NABP | MY_FNABP)) | ||
700 | 696 | DBUG_RETURN(0); /* Read went ok; Return 0 */ | ||
701 | 697 | - DBUG_RETURN(readbytes); /* purecov: inspected */ | ||
702 | 698 | + DBUG_RETURN(total_readbytes); /* purecov: inspected */ | ||
703 | 699 | } | ||
704 | 700 | } /* my_pread */ | ||
705 | 701 | |||
706 | 702 | --- a/storage/myisam/myisamdef.h | ||
707 | 703 | +++ b/storage/myisam/myisamdef.h | ||
708 | 704 | @@ -340,10 +340,10 @@ | ||
709 | 705 | int (*key_write)(struct st_mi_sort_param *, const void *); | ||
710 | 706 | void (*lock_in_memory)(MI_CHECK *); | ||
711 | 707 | int (*write_keys)(struct st_mi_sort_param *, register uchar **, | ||
712 | 708 | - uint , struct st_buffpek *, IO_CACHE *); | ||
713 | 709 | - uint (*read_to_buffer)(IO_CACHE *,struct st_buffpek *, uint); | ||
714 | 710 | + ulong , struct st_buffpek *, IO_CACHE *); | ||
715 | 711 | + ulong (*read_to_buffer)(IO_CACHE *,struct st_buffpek *, uint); | ||
716 | 712 | int (*write_key)(struct st_mi_sort_param *, IO_CACHE *,uchar *, | ||
717 | 713 | - uint, uint); | ||
718 | 714 | + uint, ulong); | ||
719 | 715 | } MI_SORT_PARAM; | ||
720 | 716 | |||
721 | 717 | /* Some defines used by isam-funktions */ | ||
722 | 718 | --- a/sql/rpl_mi.cc | ||
723 | 719 | +++ b/sql/rpl_mi.cc | ||
724 | 720 | @@ -491,7 +491,7 @@ | ||
725 | 721 | (1 + mi->ignore_server_ids.elements), MYF(MY_WME)); | ||
726 | 722 | if (!ignore_server_ids_buf) | ||
727 | 723 | DBUG_RETURN(1); | ||
728 | 724 | - ulong cur_len= sprintf(ignore_server_ids_buf, "%u", | ||
729 | 725 | + ulong cur_len= sprintf(ignore_server_ids_buf, "%lu", | ||
730 | 726 | mi->ignore_server_ids.elements); | ||
731 | 727 | for (ulong i= 0; i < mi->ignore_server_ids.elements; i++) | ||
732 | 728 | { | ||
733 | 0 | 729 | ||
734 | === modified file 'patches/series' | |||
735 | --- patches/series 2011-10-13 09:13:42 +0000 | |||
736 | +++ patches/series 2011-10-27 07:36:24 +0000 | |||
737 | @@ -59,3 +59,4 @@ | |||
738 | 59 | xtradb_bug317074.patch | 59 | xtradb_bug317074.patch |
739 | 60 | subunit.patch | 60 | subunit.patch |
740 | 61 | bug860910.patch | 61 | bug860910.patch |
741 | 62 | bug45702.patch |
http:// jenkins. percona. com/view/ Percona% 20Server% 205.5/job/ percona- server- 5.5-param/ 172/