aboutsummaryrefslogtreecommitdiff
path: root/lib/sqfshelper/statistics.c
diff options
context:
space:
mode:
Diffstat (limited to 'lib/sqfshelper/statistics.c')
-rw-r--r--lib/sqfshelper/statistics.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/lib/sqfshelper/statistics.c b/lib/sqfshelper/statistics.c
index fda4c3f..87efc30 100644
--- a/lib/sqfshelper/statistics.c
+++ b/lib/sqfshelper/statistics.c
@@ -11,11 +11,10 @@
void sqfs_print_statistics(sqfs_super_t *super, data_writer_stats_t *stats)
{
- uint64_t bytes_written = super->inode_table_start - sizeof(*super);
size_t ratio;
- if (bytes_written > 0) {
- ratio = (100 * bytes_written) / stats->bytes_read;
+ if (stats->bytes_written > 0) {
+ ratio = (100 * stats->bytes_written) / stats->bytes_read;
} else {
ratio = 100;
}