...
|
...
|
@@ -88,11 +88,11 @@ char *lzma_bswap_4861dc(struct lzmastate *p, char *old_edx)
|
88
|
88
|
return p->p0;
|
89
|
89
|
}
|
90
|
90
|
|
91
|
|
-int lzma_486248 (struct lzmastate *p, char **old_ecx, char *src, uint32_t size)
|
|
91
|
+uint32_t lzma_486248 (struct lzmastate *p, char **old_ecx, char *src, uint32_t size)
|
92
|
92
|
{
|
93
|
93
|
uint32_t loc_esi, loc_edi, loc_eax, loc_ecx, ret;
|
94
|
94
|
if (!CLI_ISCONTAINED(src, size, *old_ecx, 4) || !CLI_ISCONTAINED(src, size, p->p0, 1))
|
95
|
|
- return -1;
|
|
95
|
+ return 0xffffffff;
|
96
|
96
|
loc_esi = p->p1;
|
97
|
97
|
loc_eax = loc_esi >> 0xb;
|
98
|
98
|
loc_ecx = cli_readint32(*old_ecx);
|
...
|
...
|
@@ -150,8 +150,8 @@ uint32_t lzma_48635C(uint8_t znaczek, char **old_ecx, struct lzmastate *p, uint3
|
150
|
150
|
ret = loc_esi << 9;
|
151
|
151
|
loc_edi = *old_ecx;
|
152
|
152
|
*old_ecx = loc_edi + ret + 0x202;
|
153
|
|
- if ((ret = lzma_486248 (p, old_ecx, src, size)) == -1)
|
154
|
|
- return -1;
|
|
153
|
+ if ((ret = lzma_486248 (p, old_ecx, src, size)) == 0xffffffff)
|
|
154
|
+ return 0xffffffff;
|
155
|
155
|
loc_ebx = ret | 2;
|
156
|
156
|
|
157
|
157
|
while (loc_esi == ret)
|
...
|
...
|
@@ -166,8 +166,8 @@ uint32_t lzma_48635C(uint8_t znaczek, char **old_ecx, struct lzmastate *p, uint3
|
166
|
166
|
znaczek <<= 1;
|
167
|
167
|
ret = ((loc_esi + 1) << 8) + loc_ebx;
|
168
|
168
|
*old_ecx = loc_edi + ret*2;
|
169
|
|
- if ((ret = lzma_486248 (p, old_ecx, src, size)) == -1)
|
170
|
|
- return -1;
|
|
169
|
+ if ((ret = lzma_486248 (p, old_ecx, src, size)) == 0xffffffff)
|
|
170
|
+ return 0xffffffff;
|
171
|
171
|
loc_ebx += loc_ebx;
|
172
|
172
|
loc_ebx |= ret;
|
173
|
173
|
}
|
...
|
...
|
@@ -176,8 +176,8 @@ uint32_t lzma_48635C(uint8_t znaczek, char **old_ecx, struct lzmastate *p, uint3
|
176
|
176
|
{
|
177
|
177
|
loc_ebx += loc_ebx;
|
178
|
178
|
*old_ecx = loc_edi + loc_ebx;
|
179
|
|
- if ((ret = lzma_486248 (p, old_ecx, src, size)) == -1)
|
180
|
|
- return -1;
|
|
179
|
+ if ((ret = lzma_486248 (p, old_ecx, src, size)) == 0xffffffff)
|
|
180
|
+ return 0xffffffff;
|
181
|
181
|
loc_ebx |= ret;
|
182
|
182
|
}
|
183
|
183
|
ret = (ret&0xffffff00) | (loc_ebx&0xff);
|
...
|
...
|
@@ -200,8 +200,8 @@ uint32_t lzma_4862e0 (struct lzmastate *p, char **old_ecx, uint32_t *old_edx, ui
|
200
|
200
|
do {
|
201
|
201
|
loc_esi = ret+ret;
|
202
|
202
|
*old_ecx = loc_edi + loc_esi;
|
203
|
|
- if ((ret = lzma_486248 (p, old_ecx, src, size)) == -1)
|
204
|
|
- return -1;
|
|
203
|
+ if ((ret = lzma_486248 (p, old_ecx, src, size)) == 0xffffffff)
|
|
204
|
+ return 0xffffffff;
|
205
|
205
|
ret += loc_esi;
|
206
|
206
|
stack_ecx--;
|
207
|
207
|
} while (stack_ecx);
|
...
|
...
|
@@ -223,20 +223,20 @@ uint32_t lzma_4863da (uint32_t var0, struct lzmastate *p, char **old_ecx, uint3
|
223
|
223
|
uint32_t ret;
|
224
|
224
|
char *loc_esi = *old_ecx;
|
225
|
225
|
|
226
|
|
- if ((ret = lzma_486248 (p, old_ecx, src, size)) == -1)
|
|
226
|
+ if ((ret = lzma_486248 (p, old_ecx, src, size)) == 0xffffffff)
|
227
|
227
|
return -1;
|
228
|
228
|
if (ret)
|
229
|
229
|
{
|
230
|
230
|
/* loc_4863ff */
|
231
|
231
|
*old_ecx = loc_esi+2;
|
232
|
|
- if ((ret = lzma_486248 (p, old_ecx, src, size)) == -1)
|
|
232
|
+ if ((ret = lzma_486248 (p, old_ecx, src, size)) == 0xffffffff)
|
233
|
233
|
return -1;
|
234
|
234
|
if (ret)
|
235
|
235
|
{
|
236
|
236
|
/* loc_486429 */
|
237
|
237
|
*old_edx = 8;
|
238
|
238
|
*old_ecx = loc_esi + 0x204;
|
239
|
|
- if (lzma_4862e0 (p, old_ecx, old_edx, &ret, src, size) == -1)
|
|
239
|
+ if (lzma_4862e0 (p, old_ecx, old_edx, &ret, src, size) == 0xffffffff)
|
240
|
240
|
return -1;
|
241
|
241
|
ret += 0x10;
|
242
|
242
|
} else {
|
...
|
...
|
@@ -244,7 +244,7 @@ uint32_t lzma_4863da (uint32_t var0, struct lzmastate *p, char **old_ecx, uint3
|
244
|
244
|
ret = var0 << 4;
|
245
|
245
|
*old_edx = 3;
|
246
|
246
|
*old_ecx = loc_esi + 0x104 + ret;
|
247
|
|
- if (lzma_4862e0 (p, old_ecx, old_edx, &ret, src, size) == -1)
|
|
247
|
+ if (lzma_4862e0 (p, old_ecx, old_edx, &ret, src, size) == 0xffffffff)
|
248
|
248
|
return -1;
|
249
|
249
|
ret += 0x8;
|
250
|
250
|
}
|
...
|
...
|
@@ -253,7 +253,7 @@ uint32_t lzma_4863da (uint32_t var0, struct lzmastate *p, char **old_ecx, uint3
|
253
|
253
|
ret = var0 << 4;
|
254
|
254
|
*old_edx = 3;
|
255
|
255
|
*old_ecx = loc_esi + 0x4 + ret;
|
256
|
|
- if (lzma_4862e0 (p, old_ecx, old_edx, &ret, src, size) == -1)
|
|
256
|
+ if (lzma_4862e0 (p, old_ecx, old_edx, &ret, src, size) == 0xffffffff)
|
257
|
257
|
return -1;
|
258
|
258
|
}
|
259
|
259
|
*retval = ret;
|
...
|
...
|
@@ -283,7 +283,7 @@ uint32_t lzma_486204 (struct lzmastate *p, uint32_t old_edx, uint32_t *retval, c
|
283
|
283
|
if (loc_esi < 0x1000000)
|
284
|
284
|
{
|
285
|
285
|
if (!CLI_ISCONTAINED(src, size, p->p0, 1))
|
286
|
|
- return -1;
|
|
286
|
+ return 0xffffffff;
|
287
|
287
|
loc_edx = p->p0;
|
288
|
288
|
loc_edi <<= 8;
|
289
|
289
|
loc_esi <<= 8;
|
...
|
...
|
@@ -321,8 +321,8 @@ uint32_t lzma_48631a (struct lzmastate *p, char **old_ecx, uint32_t *old_edx, ui
|
321
|
321
|
do {
|
322
|
322
|
loc_esi = *old_edx + *old_edx;
|
323
|
323
|
*old_ecx = loc_esi + loc_ebx;
|
324
|
|
- if ((ret = lzma_486248 (p, old_ecx, src, size)) == -1)
|
325
|
|
- return -1;
|
|
324
|
+ if ((ret = lzma_486248 (p, old_ecx, src, size)) == 0xffffffff)
|
|
325
|
+ return 0xffffffff;
|
326
|
326
|
/* unneeded *old_ecx = loc_edi; */
|
327
|
327
|
*old_edx = loc_esi + ret;
|
328
|
328
|
/* ret <<= (uint32_t)(*old_ecx)&0xff; */
|
...
|
...
|
@@ -338,15 +338,19 @@ uint32_t lzma_48631a (struct lzmastate *p, char **old_ecx, uint32_t *old_edx, ui
|
338
|
338
|
|
339
|
339
|
int mew_lzma(char *orgsource, char *buf, uint32_t size_sum, uint32_t vma, uint32_t special)
|
340
|
340
|
{
|
341
|
|
- uint32_t var08, var0C, var10, var14, var18, var20, var24, var28, var34;
|
|
341
|
+ uint32_t var08, var0C, var10, var14, var20, var24, var28, var34;
|
342
|
342
|
struct lzmastate var40;
|
343
|
|
- uint32_t new_eax, new_edx, temp, loc_edi, loc_esi;
|
|
343
|
+ uint32_t new_eax, new_edx, temp;
|
344
|
344
|
int i, mainloop;
|
|
345
|
+
|
345
|
346
|
char var1, var30;
|
346
|
347
|
char *source = buf, *dest, *new_ebx, *new_ecx, *var0C_ecxcopy, *var2C;
|
347
|
348
|
char *pushed_esi = NULL, *pushed_ebx = NULL;
|
348
|
349
|
uint32_t pushed_edx=0;
|
349
|
350
|
|
|
351
|
+ uint32_t loc_esi, loc_edi;
|
|
352
|
+ uint8_t *var18;
|
|
353
|
+
|
350
|
354
|
if (special)
|
351
|
355
|
{
|
352
|
356
|
pushed_edx = cli_readint32(source);
|
...
|
...
|
@@ -372,7 +376,7 @@ int mew_lzma(char *orgsource, char *buf, uint32_t size_sum, uint32_t vma, uint32
|
372
|
372
|
var28 = cli_readint32 (source);
|
373
|
373
|
source += 4;
|
374
|
374
|
temp = cli_readint32 (source) - vma;
|
375
|
|
- var18 = (uint32_t)orgsource + temp;
|
|
375
|
+ var18 = orgsource + temp;
|
376
|
376
|
if (special) pushed_esi = orgsource + temp;
|
377
|
377
|
source += 4;
|
378
|
378
|
temp = cli_readint32 (source);
|
...
|
...
|
@@ -406,7 +410,7 @@ int mew_lzma(char *orgsource, char *buf, uint32_t size_sum, uint32_t vma, uint32
|
406
|
406
|
new_eax = var08 & 3;
|
407
|
407
|
new_ecx = (((loc_esi << 4) + new_eax)*2) + new_ebx;
|
408
|
408
|
var0C = new_eax;
|
409
|
|
- if ((new_eax = lzma_486248 (&var40, &new_ecx, orgsource, size_sum)) == -1)
|
|
409
|
+ if ((new_eax = lzma_486248 (&var40, &new_ecx, orgsource, size_sum)) == 0xffffffff)
|
410
|
410
|
return -1;
|
411
|
411
|
if (new_eax)
|
412
|
412
|
{
|
...
|
...
|
@@ -414,7 +418,7 @@ int mew_lzma(char *orgsource, char *buf, uint32_t size_sum, uint32_t vma, uint32
|
414
|
414
|
new_ecx = new_ebx + loc_esi*2 + 0x180;
|
415
|
415
|
var20 = 1;
|
416
|
416
|
/* eax=1 */
|
417
|
|
- if ((new_eax = lzma_486248 (&var40, &new_ecx, orgsource, size_sum)) == -1)
|
|
417
|
+ if ((new_eax = lzma_486248 (&var40, &new_ecx, orgsource, size_sum)) == 0xffffffff)
|
418
|
418
|
return -1;
|
419
|
419
|
if (new_eax != 1)
|
420
|
420
|
{
|
...
|
...
|
@@ -427,7 +431,7 @@ int mew_lzma(char *orgsource, char *buf, uint32_t size_sum, uint32_t vma, uint32
|
427
|
427
|
new_ecx = new_ebx + 0x664;
|
428
|
428
|
var14 = loc_edi;
|
429
|
429
|
loc_esi = new_eax;
|
430
|
|
- if (lzma_4863da (var0C, &var40, &new_ecx, &new_edx, &new_eax, orgsource, size_sum) == -1)
|
|
430
|
+ if (lzma_4863da (var0C, &var40, &new_ecx, &new_edx, &new_eax, orgsource, size_sum) == 0xffffffff)
|
431
|
431
|
return -1;
|
432
|
432
|
var0C = new_eax;
|
433
|
433
|
if (var0C >= 4)
|
...
|
...
|
@@ -437,7 +441,7 @@ int mew_lzma(char *orgsource, char *buf, uint32_t size_sum, uint32_t vma, uint32
|
437
|
437
|
new_edx = 6;
|
438
|
438
|
new_eax <<= 7;
|
439
|
439
|
new_ecx = new_eax + new_ebx + 0x360;
|
440
|
|
- if (lzma_4862e0 (&var40, &new_ecx, &new_edx, &new_eax, orgsource, size_sum) == -1)
|
|
440
|
+ if (lzma_4862e0 (&var40, &new_ecx, &new_edx, &new_eax, orgsource, size_sum) == 0xffffffff)
|
441
|
441
|
return -1;
|
442
|
442
|
if (new_eax < 4)
|
443
|
443
|
{
|
...
|
...
|
@@ -452,7 +456,7 @@ int mew_lzma(char *orgsource, char *buf, uint32_t size_sum, uint32_t vma, uint32
|
452
|
452
|
{
|
453
|
453
|
/* loc_4866ab */
|
454
|
454
|
new_edx = loc_ecx - 4;
|
455
|
|
- if (lzma_486204 (&var40, new_edx, &new_eax, orgsource, size_sum) == -1)
|
|
455
|
+ if (lzma_486204 (&var40, new_edx, &new_eax, orgsource, size_sum) == 0xffffffff)
|
456
|
456
|
return -1;
|
457
|
457
|
loc_edi += new_eax << 4;
|
458
|
458
|
|
...
|
...
|
@@ -465,7 +469,7 @@ int mew_lzma(char *orgsource, char *buf, uint32_t size_sum, uint32_t vma, uint32
|
465
|
465
|
new_ecx = new_ebx + loc_ecx*2 + 0x55e;
|
466
|
466
|
}
|
467
|
467
|
/* loc_4866a2 */
|
468
|
|
- if (lzma_48631a (&var40, &new_ecx, &new_edx, &new_eax, orgsource, size_sum) == -1)
|
|
468
|
+ if (lzma_48631a (&var40, &new_ecx, &new_edx, &new_eax, orgsource, size_sum) == 0xffffffff)
|
469
|
469
|
return -1;
|
470
|
470
|
loc_edi += new_eax;
|
471
|
471
|
}
|
...
|
...
|
@@ -473,19 +477,19 @@ int mew_lzma(char *orgsource, char *buf, uint32_t size_sum, uint32_t vma, uint32
|
473
|
473
|
} else {
|
474
|
474
|
/* loc_486568 */
|
475
|
475
|
new_ecx = new_ebx + loc_esi*2 + 0x198;
|
476
|
|
- if ((new_eax = lzma_486248 (&var40, &new_ecx, orgsource, size_sum)) == -1)
|
|
476
|
+ if ((new_eax = lzma_486248 (&var40, &new_ecx, orgsource, size_sum)) == 0xffffffff)
|
477
|
477
|
return -1;
|
478
|
478
|
if (new_eax)
|
479
|
479
|
{
|
480
|
480
|
/* loc_4865bd */
|
481
|
481
|
new_ecx = new_ebx + loc_esi*2 + 0x1B0;
|
482
|
|
- if ((new_eax = lzma_486248 (&var40, &new_ecx, orgsource, size_sum)) == -1)
|
|
482
|
+ if ((new_eax = lzma_486248 (&var40, &new_ecx, orgsource, size_sum)) == 0xffffffff)
|
483
|
483
|
return -1;
|
484
|
484
|
if (new_eax)
|
485
|
485
|
{
|
486
|
486
|
/* loc_4865d2 */
|
487
|
487
|
new_ecx = new_ebx + loc_esi*2 + 0x1C8;
|
488
|
|
- if ((new_eax = lzma_486248 (&var40, &new_ecx, orgsource, size_sum)) == -1)
|
|
488
|
+ if ((new_eax = lzma_486248 (&var40, &new_ecx, orgsource, size_sum)) == 0xffffffff)
|
489
|
489
|
return -1;
|
490
|
490
|
if (new_eax) {
|
491
|
491
|
/* loc_4865ea */
|
...
|
...
|
@@ -508,7 +512,7 @@ int mew_lzma(char *orgsource, char *buf, uint32_t size_sum, uint32_t vma, uint32
|
508
|
508
|
/* loc_48657e */
|
509
|
509
|
new_eax = ((loc_esi + 0xf) << 4) + var0C;
|
510
|
510
|
new_ecx = new_ebx + new_eax*2;
|
511
|
|
- if ((new_eax = lzma_486248 (&var40, &new_ecx, orgsource, size_sum)) == -1)
|
|
511
|
+ if ((new_eax = lzma_486248 (&var40, &new_ecx, orgsource, size_sum)) == 0xffffffff)
|
512
|
512
|
return -1;
|
513
|
513
|
if (!new_eax) {
|
514
|
514
|
uint32_t loc_ecx;
|
...
|
...
|
@@ -517,18 +521,15 @@ int mew_lzma(char *orgsource, char *buf, uint32_t size_sum, uint32_t vma, uint32
|
517
|
517
|
loc_ecx -= loc_edi;
|
518
|
518
|
/* loc_esi = ((((loc_esi >= 7)-1)&0xFFFFFFFE) + 0xB); */
|
519
|
519
|
loc_esi = loc_esi>=7 ? 11:9;
|
520
|
|
- new_eax = var18;
|
521
|
|
- if (!CLI_ISCONTAINED(orgsource, size_sum, (char*)(new_eax + loc_ecx), 1))
|
|
520
|
+ if (!CLI_ISCONTAINED((uint8_t *)orgsource, size_sum, var18 + loc_ecx, 1))
|
522
|
521
|
return -1;
|
523
|
|
- var1 = *(uint8_t *)(new_eax + loc_ecx);
|
|
522
|
+ var1 = *(var18 + loc_ecx);
|
524
|
523
|
loc_ecx = (loc_ecx&0xffffff00) | var1;
|
525
|
524
|
/* loc_4865af */
|
526
|
525
|
new_edx = var08++;
|
527
|
|
- if (!CLI_ISCONTAINED(orgsource, size_sum, (char*)(new_eax + new_edx), 1))
|
|
526
|
+ if (!CLI_ISCONTAINED((uint8_t *)orgsource, size_sum, var18 + new_edx, 1))
|
528
|
527
|
return -1;
|
529
|
|
- *(uint8_t *)(new_eax + new_edx) = loc_ecx & 0xff;
|
530
|
|
-
|
531
|
|
- new_ecx = (char*)loc_ecx;
|
|
528
|
+ *(var18 + new_edx) = loc_ecx & 0xff;
|
532
|
529
|
|
533
|
530
|
/* loc_4866fe */
|
534
|
531
|
new_eax = var08;
|
...
|
...
|
@@ -538,7 +539,7 @@ int mew_lzma(char *orgsource, char *buf, uint32_t size_sum, uint32_t vma, uint32
|
538
|
538
|
}
|
539
|
539
|
/* loc_4865fe */
|
540
|
540
|
new_ecx = new_ebx + 0xa68;
|
541
|
|
- if (lzma_4863da (var0C, &var40, &new_ecx, &new_edx, &new_eax, orgsource, size_sum) == -1)
|
|
541
|
+ if (lzma_4863da (var0C, &var40, &new_ecx, &new_edx, &new_eax, orgsource, size_sum) == 0xffffffff)
|
542
|
542
|
return -1;
|
543
|
543
|
var0C = new_eax;
|
544
|
544
|
/* new_eax = (((loc_esi >= 7)-1)&0xFFFFFFFD) + 0xB; */
|
...
|
...
|
@@ -551,7 +552,7 @@ int mew_lzma(char *orgsource, char *buf, uint32_t size_sum, uint32_t vma, uint32
|
551
|
551
|
break;
|
552
|
552
|
} else {
|
553
|
553
|
var0C += 2;
|
554
|
|
- new_ecx = (char*)var18;
|
|
554
|
+ new_ecx = var18;
|
555
|
555
|
new_edx = new_eax = var08;
|
556
|
556
|
new_eax -= loc_edi;
|
557
|
557
|
if ( ((var0C < var28 - new_edx) &&
|
...
|
...
|
@@ -599,7 +600,7 @@ int mew_lzma(char *orgsource, char *buf, uint32_t size_sum, uint32_t vma, uint32
|
599
|
599
|
new_eax += new_eax;
|
600
|
600
|
new_ecx += new_eax;
|
601
|
601
|
var34 = new_eax;
|
602
|
|
- if ((new_eax = lzma_486248(&var40, &new_ecx, orgsource, size_sum)) == -1)
|
|
602
|
+ if ((new_eax = lzma_486248(&var40, &new_ecx, orgsource, size_sum)) == 0xffffffff)
|
603
|
603
|
return -1;
|
604
|
604
|
new_eax |= var34;
|
605
|
605
|
/* loc_486522 */
|
...
|
...
|
@@ -616,30 +617,29 @@ int mew_lzma(char *orgsource, char *buf, uint32_t size_sum, uint32_t vma, uint32
|
616
|
616
|
} else {
|
617
|
617
|
int t;
|
618
|
618
|
/* loc_4864FB */
|
619
|
|
- new_edx = var18;
|
620
|
619
|
new_eax = var08 - loc_edi;
|
621
|
|
- if (!CLI_ISCONTAINED(orgsource, size_sum, (char*)(new_eax + new_edx), 1))
|
|
620
|
+ if (!CLI_ISCONTAINED((uint8_t *)orgsource, size_sum, var18 + new_eax, 1))
|
622
|
621
|
return -1;
|
623
|
|
- t = *(uint8_t *)(new_eax+new_edx);
|
|
622
|
+ t = *(var18+new_eax);
|
624
|
623
|
new_eax = (new_eax&0xffffff00) | t;
|
625
|
|
- /*new_edx = (uint32_t)&var40;*/
|
|
624
|
+
|
626
|
625
|
var30 = t;
|
627
|
|
- if (lzma_48635C (t, &new_ecx, &var40, &new_eax, orgsource, size_sum) == -1)
|
|
626
|
+ if (lzma_48635C (t, &new_ecx, &var40, &new_eax, orgsource, size_sum) == 0xffffffff)
|
628
|
627
|
return -1;
|
629
|
628
|
var20 = 0;
|
630
|
629
|
var1 = new_eax&0xff;
|
631
|
630
|
}
|
632
|
631
|
|
633
|
632
|
/* loc_486541 */
|
634
|
|
- new_eax = var18;
|
|
633
|
+
|
635
|
634
|
/* unneeded: new_ecx = (new_ecx&0xffffff00) | var1; */
|
636
|
635
|
|
637
|
636
|
/* loc_4865af */
|
638
|
637
|
new_edx = var08++;
|
639
|
638
|
|
640
|
|
- if (!CLI_ISCONTAINED(orgsource, size_sum, (char*)(new_eax + new_edx), 1))
|
|
639
|
+ if (!CLI_ISCONTAINED((uint8_t *)orgsource, size_sum, var18 + new_edx, 1))
|
641
|
640
|
return -1;
|
642
|
|
- *(uint8_t *)(new_eax + new_edx) = var1;
|
|
641
|
+ *(var18 + new_edx) = var1;
|
643
|
642
|
}
|
644
|
643
|
/* loc_4866fe */
|
645
|
644
|
new_eax = var08;
|
...
|
...
|
@@ -686,7 +686,7 @@ uint32_t lzma_upack_esi_00(struct lzmastate *p, char *old_ecx, char *bb, uint32_
|
686
|
686
|
cli_dbgmsg("contain error! %08x %08x ecx: %08x [%08x]\n", bb, bl, old_ecx,bb+bl);
|
687
|
687
|
else
|
688
|
688
|
cli_dbgmsg("contain error! %08x %08x p0: %08x [%08x]\n", bb, bl, p->p0,bb+bl);
|
689
|
|
- return -1;
|
|
689
|
+ return 0xffffffff;
|
690
|
690
|
}
|
691
|
691
|
ret = cli_readint32(old_ecx);
|
692
|
692
|
loc_eax *= ret;
|
...
|
...
|
@@ -724,8 +724,8 @@ uint32_t lzma_upack_esi_50(struct lzmastate *p, uint32_t old_eax, uint32_t old_e
|
724
|
724
|
|
725
|
725
|
do {
|
726
|
726
|
*old_edx = old_ebp + (loc_eax<<2);
|
727
|
|
- if ((ret = lzma_upack_esi_00(p, *old_edx, bs, bl)) == -1)
|
728
|
|
- return -1;
|
|
727
|
+ if ((ret = lzma_upack_esi_00(p, *old_edx, bs, bl)) == 0xffffffff)
|
|
728
|
+ return 0xffffffff;
|
729
|
729
|
loc_eax += loc_eax;
|
730
|
730
|
loc_eax += ret;
|
731
|
731
|
} while (loc_eax < old_ecx);
|
...
|
...
|
@@ -754,7 +754,7 @@ uint32_t lzma_upack_esi_54(struct lzmastate *p, uint32_t old_eax, uint32_t *old_
|
754
|
754
|
}
|
755
|
755
|
}
|
756
|
756
|
ret = loc_eax;
|
757
|
|
- if (lzma_upack_esi_50(p, 1, *old_ecx, old_edx, *old_edx + (loc_eax << 2), &loc_eax, bs, bl) == -1)
|
|
757
|
+ if (lzma_upack_esi_50(p, 1, *old_ecx, old_edx, *old_edx + (loc_eax << 2), &loc_eax, bs, bl) == 0xffffffff)
|
758
|
758
|
return -1;
|
759
|
759
|
|
760
|
760
|
*retval = ret + loc_eax;
|