Open GoogleCodeExporter opened 8 years ago
The likely fix would be to change the assumption made for ip value in this for
loop
and allow only 6 increments as safe condition for FASTLZ_LEVEL 2. The
assumption of 8
increments is safe only for FASTLZ_LEVEL 1.
275 for(;;)
276 {
277 /* safe because the outer check against ip limit */
278 if(*ref++ != *ip++) break;
279 if(*ref++ != *ip++) break;
280 if(*ref++ != *ip++) break;
281 if(*ref++ != *ip++) break;
282 if(*ref++ != *ip++) break;
283 if(*ref++ != *ip++) break;
284 #if FASTLZ_LEVEL==1
285 if(*ref++ != *ip++) break;
286 if(*ref++ != *ip++) break;
287 #endif
288 while(ip < ip_bound)
289 if(*ref++ != *ip++) break;
290 break;
291 }
Original comment by aditya...@gmail.com
on 2 Feb 2010 at 10:31
Original issue reported on code.google.com by
aditya...@gmail.com
on 2 Feb 2010 at 10:30