From: Theodore Ts'o Date: Wed, 5 Jul 2000 18:25:59 +0000 (+0000) Subject: ChangeLog, unix.c: X-Git-Tag: E2FSPROGS-1_19~15 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=9226904bfb091de44ef7758936c61148c5ccf997;p=thirdparty%2Fe2fsprogs.git ChangeLog, unix.c: unix.c (e2fsck_update_progress): Only save and check the last percentage after multiplying it by 10, nor 1000, since we only need to save values to a tenth of a percent (and the percentage is already from 0 .. 100%, not 0 .. 1). --- diff --git a/e2fsck/ChangeLog b/e2fsck/ChangeLog index 4bce316ec..3aa67c2f8 100644 --- a/e2fsck/ChangeLog +++ b/e2fsck/ChangeLog @@ -1,3 +1,10 @@ +2000-07-05 Theodore Ts'o + + * unix.c (e2fsck_update_progress): Only save and check the last + percentage after multiplying it by 10, nor 1000, since we + only need to save values to a tenth of a percent (and the + percentage is already from 0 .. 100%, not 0 .. 1). + 2000-07-04 Theodore Ts'o * pass1.c (e2fsck_pass1): Check to see if the ext3 s_last_orphan diff --git a/e2fsck/unix.c b/e2fsck/unix.c index 9f5d7f0e7..3b43f7d30 100644 --- a/e2fsck/unix.c +++ b/e2fsck/unix.c @@ -349,9 +349,9 @@ static int e2fsck_update_progress(e2fsck_t ctx, int pass, ctx->progress_pos = (ctx->progress_pos+1) & 3; ctx->flags |= E2F_FLAG_PROG_BAR; percent = calc_percent(&e2fsck_tbl, pass, cur, max); - if (ctx->progress_last_percent == (int) 1000 * percent) + if (ctx->progress_last_percent == (int) 10 * percent) return 0; - ctx->progress_last_percent = (int) 1000 * percent; + ctx->progress_last_percent = (int) 10 * percent; i = ((percent * dpywidth) + 50) / 100; printf("%s: |%s%s", ctx->device_name, bar + (sizeof(bar) - (i+1)),