summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDenys Vlasenko <vda.linux@googlemail.com>2018-02-03 18:47:34 +0100
committerDenys Vlasenko <vda.linux@googlemail.com>2018-02-03 18:47:34 +0100
commit0599a137ba5a6043ce6195a2c12deeaf3886f002 (patch)
tree8130d095c14a535eaa11db922686fa65f71ac175
parent8e31412231cc56e36bd4eb8410bffc78d0b252d9 (diff)
downloadbusybox-w32-0599a137ba5a6043ce6195a2c12deeaf3886f002.tar.gz
busybox-w32-0599a137ba5a6043ce6195a2c12deeaf3886f002.tar.bz2
busybox-w32-0599a137ba5a6043ce6195a2c12deeaf3886f002.zip
bzip2: a few more locals converted to generic types
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
-rw-r--r--archival/libarchive/bz/blocksort.c14
1 files changed, 7 insertions, 7 deletions
diff --git a/archival/libarchive/bz/blocksort.c b/archival/libarchive/bz/blocksort.c
index 9de9cc3cc..a1ee59224 100644
--- a/archival/libarchive/bz/blocksort.c
+++ b/archival/libarchive/bz/blocksort.c
@@ -452,7 +452,7 @@ int mainGtU(
452 * usually small, typically <= 20. 452 * usually small, typically <= 20.
453 */ 453 */
454static 454static
455const int32_t incs[14] = { 455const uint32_t incs[14] = {
456 1, 4, 13, 40, 121, 364, 1093, 3280, 456 1, 4, 13, 40, 121, 364, 1093, 3280,
457 9841, 29524, 88573, 265720, 457 9841, 29524, 88573, 265720,
458 797161, 2391484 458 797161, 2391484
@@ -468,7 +468,8 @@ void mainSimpleSort(uint32_t* ptr,
468 int32_t d, 468 int32_t d,
469 int32_t* budget) 469 int32_t* budget)
470{ 470{
471 int32_t bigN, hp; 471 int32_t bigN;
472 int hp;
472 473
473 bigN = hi - lo + 1; 474 bigN = hi - lo + 1;
474 if (bigN < 2) return; 475 if (bigN < 2) return;
@@ -478,15 +479,15 @@ void mainSimpleSort(uint32_t* ptr,
478 hp--; 479 hp--;
479 480
480 for (; hp >= 0; hp--) { 481 for (; hp >= 0; hp--) {
481 int32_t i, h; 482 int32_t i;
483 unsigned h;
482 484
483 h = incs[hp]; 485 h = incs[hp];
484 i = lo + h; 486 i = lo + h;
485 while (1) { 487 while (1) {
486 int32_t j; 488 unsigned j;
487 uint32_t v; 489 unsigned v;
488 490
489 /*-- copy 1 --*/
490 if (i > hi) break; 491 if (i > hi) break;
491 v = ptr[i]; 492 v = ptr[i];
492 j = i; 493 j = i;
@@ -511,7 +512,6 @@ void mainSimpleSort(uint32_t* ptr,
511 } 512 }
512 ptr[j] = v; 513 ptr[j] = v;
513 i++; 514 i++;
514
515 /*-- copy 3 --*/ 515 /*-- copy 3 --*/
516 if (i > hi) break; 516 if (i > hi) break;
517 v = ptr[i]; 517 v = ptr[i];